@@ -72,38 +72,40 @@ optional arguments:
72
72
[env var: MARGE_AUTH_TOKEN_FILE] (default: None)
73
73
--gitlab-url URL Your GitLab instance, e.g. " https://gitlab.example.com" .
74
74
[env var: MARGE_GITLAB_URL] (default: None)
75
+ --use-https use HTTP(S) instead of SSH for GIT repository access
76
+ [env var: MARGE_USE_HTTPS] (default: False)
75
77
--ssh-key KEY The private ssh key for marge so it can clone/push.
76
78
DISABLED because passing credentials on the command line is insecure:
77
79
You can still set it via ENV variable or config file, or use " --ssh-key-file" flag.
78
80
[env var: MARGE_SSH_KEY] (default: None)
79
81
--ssh-key-file FILE Path to the private ssh key for marge so it can clone/push.
80
82
[env var: MARGE_SSH_KEY_FILE] (default: None)
81
83
--embargo INTERVAL[,..]
82
- Time(s) during which no merging is to take place, e.g. " Friday 1pm - Monday 9am"
83
- or " Fri 12:30 Europe/London - Mon 08:00 Europe/London"
84
+ Time(s) during which no merging is to take place, e.g. " Friday 1pm - Monday 9am" .
84
85
[env var: MARGE_EMBARGO] (default: None)
85
86
--use-merge-strategy Use git merge instead of git rebase to update the * source* branch (EXPERIMENTAL)
86
87
If you need to use a strict no-rebase workflow (in most cases
87
88
you don' t want this, even if you configured gitlab to use merge requests
88
89
to use merge commits on the *target* branch (the default).)
89
90
[env var: MARGE_USE_MERGE_STRATEGY] (default: False)
91
+ --rebase-remotely Instead of rebasing in a local clone of the repository, use GitLab' s
92
+ built-in rebase functionality, via their API. Note that Marge can' t add
93
+ information in the commits in this case.
94
+ [env var: MARGE_REBASE_REMOTELY] (default: False)
90
95
--add-tested Add "Tested: marge-bot <$MR_URL>" for the final commit on branch after it passed CI.
91
96
[env var: MARGE_ADD_TESTED] (default: False)
92
97
--batch Enable processing MRs in batches
93
98
[env var: MARGE_BATCH] (default: False)
94
- --use-no-ff-batches Disable fast forwarding when merging MR batches.
95
- [env var: MARGE_USE_NO_FF_BATCHES] (default: False)
96
99
--add-part-of Add "Part-of: <$MR_URL>" to each commit in MR.
97
100
[env var: MARGE_ADD_PART_OF] (default: False)
98
101
--add-reviewers Add "Reviewed-by: $approver" for each approver of MR to each commit in MR.
99
102
[env var: MARGE_ADD_REVIEWERS] (default: False)
100
103
--impersonate-approvers
101
104
Marge-bot pushes effectively don' t change approval status.
102
105
[env var: MARGE_IMPERSONATE_APPROVERS] (default: False)
103
- --merge-order The order you want marge to merge its requests.
104
- As of earliest merge request creation time (created_at), update time (updated_at)
105
- or assigned to ' marge-bot' user time (assigned_at)
106
- [env var: MARGE_MERGE_ORDER] (default: created_at)
106
+ --merge-order {created_at,updated_at,assigned_at}
107
+ Order marge merges assigned requests. created_at (default), updated_at or assigned_at.
108
+ [env var: MARGE_MERGE_ORDER] (default: created_at)
107
109
--approval-reset-timeout APPROVAL_RESET_TIMEOUT
108
110
How long to wait for approvals to reset after pushing.
109
111
Only useful with the " new commits remove all approvals" option in a project' s settings.
@@ -136,6 +138,11 @@ optional arguments:
136
138
--cli Run marge-bot as a single CLI command, not as a long-running service.
137
139
This may be used to run marge-bot in scheduled CI pipelines or cronjobs.
138
140
[env var: MARGE_CLI] (default: False)
141
+ --use-no-ff-batches Disable fast forwarding when merging MR batches [env var: MARGE_USE_NO_FF_BATCHES] (default: False)
142
+ --use-merge-commit-batches
143
+ Use merge commit when creating batches, so that the commits in the batch MR will be the same with in individual MRs. Requires sudo scope in the access token.
144
+ [env var: MARGE_USE_MERGE_COMMIT_BATCHES] (default: False)
145
+ --skip-ci-batches Skip CI when updating individual MRs when using batches [env var: MARGE_SKIP_CI_BATCHES] (default: False)
139
146
` ` `
140
147
Here is a config file example
141
148
` ` ` yaml
@@ -156,6 +163,8 @@ project-regexp: .*
156
163
# choose one way of specifying the SSH key
157
164
# ssh-key: KEY
158
165
ssh-key-file: token.FILE
166
+ # OR use HTTPS instead of SSH
167
+ # use-https: true
159
168
` ` `
160
169
For more information about configuring marge-bot see ` --help`
161
170
@@ -203,7 +212,7 @@ ssh-keygen -t ed25519 -C marge-bot@invalid -f marge-bot-ssh-key -P ''
203
212
Add the public key (` marge-bot-ssh-key.pub` ) to the user' s `SSH Keys` in GitLab
204
213
and keep the private one handy.
205
214
206
- ### Running marge-bot in docker (what we do)
215
+ ### Running marge-bot in docker using SSH (what we do)
207
216
208
217
Assuming you have already got docker installed, the quickest and most minimal
209
218
way to run marge is like so (*but see note about passing secrets on the
@@ -256,6 +265,22 @@ may contain bugs.
256
265
You can also specify a particular version as a tag, e.g.
257
266
`smarkets/marge-bot:0.7.0`.
258
267
268
+ ### Running marge-bot in docker using HTTPS
269
+
270
+ It is also possible to use Git over HTTPS instead of Git over SSH. To use HTTPS instead of SSH,
271
+ add the `--use-https` flag and do not provide any SSH keys. Alternatively you can set the
272
+ environment variable `MARGE_USE_HTTPS` or the config file property `use-https`.
273
+
274
+ ```bash
275
+ docker run --restart=on-failure \ # restart if marge crashes because GitLab is flaky
276
+ -e MARGE_AUTH_TOKEN="$(cat marge-bot.token)" \
277
+ smarkets/marge-bot \
278
+ --use-https \
279
+ --gitlab-url=' http://your.gitlab.instance.com'
280
+ ```
281
+
282
+ HTTPS can be used using any other deployment technique as well.
283
+
259
284
### Running marge-bot in kubernetes
260
285
It' s also possible to run marge in kubernetes, e.g. here' s how you use a ktmpl
261
286
template:
0 commit comments