Closed Hi-Angel closed 3 years ago
Alright, so, after debugging marge-bot for a bit I figured, the reason it does not wait is completely valid: it checks gitlab variable only_allow_merge_if_pipeline_succeeds
, and uses its value.
The reason we had not this set is because I was pretty sure it is an enterprise-only feature. I dunno, maybe it was, but later then they changed they mind… Anyway, as of gitlab 13.6.1 this is available in community edition as well. Changing it can be done at Settings → General → Merge requests → ✓ Pipelines must succeed
.
Actually, I think I'll reopen this. I'm gonna send a PR with docs on that matter, which then would close the issue.
As far as I read README and the linked blog-post, no additional configuration is required for the bot to only merge an MR after pipeline passes. However, for us the bot always merges an MR immediately
Here's a screenshot:
You can see the pipeline haven't even been started, but the bot already merged MR. The
.gitlab-ci.yml
I have used for this test is:Bot configuration file:
Relevant logs by the bot (I have changed project and domain names):
Version the bot refuses to tell (apparently there's no way to request it its version), but the podman/docker container smarkets/marge-bot is by 14 December 2020 (yesterday as of writing the words)