diff --git a/.gitlab/CI/publish.gitlab-ci.yml b/.gitlab/CI/publish.gitlab-ci.yml index 21b82d3cbd..08fc073284 100644 --- a/.gitlab/CI/publish.gitlab-ci.yml +++ b/.gitlab/CI/publish.gitlab-ci.yml @@ -4,14 +4,14 @@ stage: publish rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_PIPELINE_SOURCE != "schedule" - when: always + when: on_success - when: never .publish-nightly: stage: publish rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_PIPELINE_SOURCE == "schedule" - when: always + when: on_success - when: never docker: diff --git a/.gitlab/CI/release.yml b/.gitlab/CI/release.yml index 6fa6378edd..87484d7816 100644 --- a/.gitlab/CI/release.yml +++ b/.gitlab/CI/release.yml @@ -12,7 +12,7 @@ stage: build rules: - if: $CI_PIPELINE_SOURCE != "merge_request_event" && $CI_PIPELINE_SOURCE != "schedule" && ($CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH || $CI_COMMIT_TAG =~ /^v[0-9]+\.[0-9]+\.[0-9]+/ || $CI_COMMIT_REF_NAME =~ /^r[0-9]+\.[0-9]+/) - when: always + when: on_success - when: never # Template to only run if pushes to master or a tag happened for scheduled builds @@ -20,5 +20,5 @@ stage: build-nightly rules: - if: $CI_PIPELINE_SOURCE == "schedule" && ($CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH || $CI_COMMIT_TAG =~ /^v[0-9]+\.[0-9]+\.[0-9]+/ || $CI_COMMIT_REF_NAME =~ /^r[0-9]+\.[0-9]+/) - when: always + when: on_success - when: never