Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Don't run cargo-check-benches for master based downstream staging…
Browse files Browse the repository at this point in the history
… pipelines (#12233)
  • Loading branch information
rcny authored Sep 12, 2022
1 parent c997a62 commit 7cb78ff
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
12 changes: 12 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,18 @@ default:
- if: $CI_PIPELINE_SOURCE == "schedule"
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs

# handle the specific case where benches could store incorrect bench data because of the downstream staging runs
# exclude cargo-check-benches from such runs
.test-refs-no-trigger-prs-only-check-benches:
rules:
- if: $CI_COMMIT_REF_NAME == "master" && $CI_PIPELINE_SOURCE == "parent_pipeline" && $CI_IMAGE =~ /staging$/
when: never
- if: $CI_PIPELINE_SOURCE == "pipeline"
when: never
- if: $CI_PIPELINE_SOURCE == "web"
- if: $CI_PIPELINE_SOURCE == "schedule"
- if: $CI_COMMIT_REF_NAME =~ /^[0-9]+$/ # PRs

.test-refs-wasmer-sandbox:
rules:
- if: $CI_PIPELINE_SOURCE == "web"
Expand Down
2 changes: 1 addition & 1 deletion scripts/ci/gitlab/pipeline/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ cargo-check-benches:
CI_JOB_NAME: "cargo-check-benches"
extends:
- .docker-env
- .test-refs
- .test-refs-no-trigger-prs-only-check-benches
- .collect-artifacts
- .pipeline-stopper-artifacts
before_script:
Expand Down

0 comments on commit 7cb78ff

Please sign in to comment.