FAQ | This is a LIVE service | Changelog

Skip to content

Add auto devops merge request pipeline support

Ryan Kowalewski requested to merge add-support-for-mr-pipelines into master

This proposed template overrides all relevant GitLab Auto-DevOps job rules to allow the jobs to run in merge request pipelines. This, coupled with the included workflow rule, enables us to switch between merge request and branch pipelines and avoid the confusion caused by GitLab's annoying duplicate pipelines.

Here is an example of a branch pipeline test (including the currently problematic pre-commit-yml template mentioned in #48 (closed)):

https://gitlab.developers.cam.ac.uk/uis/devops/experiments/webapp-demo/webapp-test/-/pipelines/368078

And here is an example of the exact same pipeline, but triggered as a merge request pipeline (without a duplicate branch-based pipeline) as soon as I opened a dummy MR:

https://gitlab.developers.cam.ac.uk/uis/devops/experiments/webapp-demo/webapp-test/-/pipelines/368081

Adding this workflow is also a blocker on the ongoing semantic-release proof of concept, as the core concept of this tool is that it reviews all commits in a proposed MR to determine that they all follow the conventional commit standard so that it can determine the new semantic version number after the MR is merged.

Finally, I've used the *.gitlab-ci.yml template naming convention in anticipation of #52 (closed) being accepted as worthwhile.

Closes #53 (closed)

Merge request reports