]> granicus.if.org Git - graphviz/commitdiff
Only run macOS CI on graphviz/graphviz repo
authorMark Hansen <markhansen@google.com>
Sat, 20 Feb 2021 07:35:19 +0000 (18:35 +1100)
committerMark Hansen <markhansen@google.com>
Sat, 20 Feb 2021 07:35:19 +0000 (18:35 +1100)
Don't run on forks, which generally don't have access to macOS runners.

Fixes #1951

.gitlab-ci.yml

index 23588978004686ba0ab5d8d8aa3f439b40f143f5..71caf0ea3004125fc2abf1e9076a4535865a11dd 100644 (file)
@@ -102,6 +102,15 @@ portable-source:
             metrics: metrics.txt
     except:
         - tags
+    # Most submitters don't have access to the macOS runners, and if they try
+    # to run macOS pipeline jobs, the jobs will hang forever.  This variable is
+    # only set on repos that have access to macOS runners, in GitLab repo
+    # settings.
+    # https://gitlab.com/graphviz/graphviz/-/settings/ci_cd
+    only:
+        variables:
+          - $CI_ENABLE_MACOS
+
 
 .build_template: &windows_build_definition
     stage: build
@@ -511,6 +520,14 @@ macos-autotools-test:
           artifacts: true
     tags:
         - macos
+    # Most submitters don't have access to the macOS runners, and if they try
+    # to run macOS pipeline jobs, the jobs will hang forever.  This variable is
+    # only set on repos that have access to macOS runners, in GitLab repo
+    # settings.
+    # https://gitlab.com/graphviz/graphviz/-/settings/ci_cd
+    only:
+        variables:
+          - $CI_ENABLE_MACOS
 
 ubuntu18-04-cmake-test:
     <<: *linux_test_definition
@@ -587,6 +604,14 @@ macos-cmake-test:
           artifacts: true
     tags:
         - macos
+    # Most submitters don't have access to the macOS runners, and if they try
+    # to run macOS pipeline jobs, the jobs will hang forever.  This variable is
+    # only set on repos that have access to macOS runners, in GitLab repo
+    # settings.
+    # https://gitlab.com/graphviz/graphviz/-/settings/ci_cd
+    only:
+        variables:
+          - $CI_ENABLE_MACOS
 
 deployment:
     stage: deploy