CI: add new workflow rules
authorPeter Hutterer <peter.hutterer@who-t.net>
Tue, 14 Mar 2023 23:28:12 +0000 (09:28 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Tue, 14 Mar 2023 23:30:58 +0000 (09:30 +1000)
Required for pipelines to run after some infrastructure changes, see
https://gitlab.freedesktop.org/freedesktop/freedesktop/-/issues/438

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
.gitlab-ci.yml
.gitlab-ci/ci.template

index fc8452264af70a79d2f18ef4a60e8d8485ba2bdd..0aa404b159d5995ed791e8b0026b74b2198d3118 100644 (file)
@@ -54,6 +54,11 @@ include:
       # Ubuntu container builder template
       - '/templates/ubuntu.yml'
 
+workflow:
+  rules:
+    - if: $CI_PIPELINE_SOURCE == 'merge_request_event'
+    - if: $CI_PIPELINE_SOURCE == 'push'
+
 stages:
   - sanity check     # CI/commit checks
   - prep             # prep work like rebuilding the container images if there is a change
index 64b49775be67cda516db85ec9af2c0a95d8c7eaf..c527d2709d182bc3ce89d11dfac9d95f312db6e3 100644 (file)
@@ -48,6 +48,11 @@ include:
       - '/templates/{{distro.name}}.yml'
   {% endfor %}
 
+workflow:
+  rules:
+    - if: $CI_PIPELINE_SOURCE == 'merge_request_event'
+    - if: $CI_PIPELINE_SOURCE == 'push'
+
 stages:
   - sanity check     # CI/commit checks
   - prep             # prep work like rebuilding the container images if there is a change