gitlab CI: check merge requests for the allow collaboration checkbox
authorPeter Hutterer <peter.hutterer@who-t.net>
Mon, 15 Jun 2020 10:50:29 +0000 (20:50 +1000)
committerPeter Hutterer <peter.hutterer@who-t.net>
Mon, 15 Jun 2020 10:50:37 +0000 (20:50 +1000)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
.gitlab-ci.yml
.gitlab-ci/ci.template

index 5601e818137a8f30468094c7889a3e626c8aec37..85d923c40d2f2441a7c2871b3933e4d91f61864c 100644 (file)
@@ -166,6 +166,24 @@ check-commit:
     reports:
       junit: results.xml
 
+#
+# Verify that the merge request has the allow-collaboration checkbox ticked
+#
+
+check-merge-request:
+  image: golang:alpine
+  stage: prep
+  before_script:
+    - apk add python3 py-pip git
+    - pip3 install git+http://gitlab.freedesktop.org/freedesktop/ci-templates
+  script:
+    - ci-fairy check-merge-request --require-allow-collaboration --junit-xml=results.xml
+  artifacts:
+    when: on_failure
+    reports:
+      junit: results.xml
+  allow_failure: true
+
 #
 # This stage will recreate the container images only if the image
 # is too old or if it is missing some dependencies.
index f92efebc5f19f233a9c5b1190f842039043beeab..2295e5596e128e21dac19774f44c7dba3e92f18d 100644 (file)
@@ -162,6 +162,24 @@ check-commit:
     reports:
       junit: results.xml
 
+#
+# Verify that the merge request has the allow-collaboration checkbox ticked
+#
+
+check-merge-request:
+  image: golang:alpine
+  stage: prep
+  before_script:
+    - apk add python3 py-pip git
+    - pip3 install git+http://gitlab.freedesktop.org/freedesktop/ci-templates
+  script:
+    - ci-fairy check-merge-request --require-allow-collaboration --junit-xml=results.xml
+  artifacts:
+    when: on_failure
+    reports:
+      junit: results.xml
+  allow_failure: true
+
 #
 # This stage will recreate the container images only if the image
 # is too old or if it is missing some dependencies.