diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index da824f0faa8dd997857f3e180aae9e5128b14510..43df112830bb672e961b51bc11539eef91e60dac 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -51,7 +51,8 @@ build-dev: tags: - $RUNNER_AMD rules: - - if: '$CI_COMMIT_BRANCH != "main" && $CI_PIPELINE_SOURCE != "merge_request_event"' + # Only run if the branch is not main, the pipeline is not triggered by a merge request and the commit is not a tag + - if: '$CI_COMMIT_BRANCH != "main" && $CI_PIPELINE_SOURCE != "merge_request_event" && $CI_COMMIT_TAG == null' build-stg: extends: .docker-build-dev @@ -67,7 +68,9 @@ deploy-dev: needs: - job: build-dev rules: - - if: '$CI_COMMIT_BRANCH != "main" && $CI_PIPELINE_SOURCE != "merge_request_event"' + # Only run if the branch is not main, the pipeline is not triggered by a merge request and the commit is not a tag + - if: '$CI_COMMIT_BRANCH != "main" && $CI_PIPELINE_SOURCE != "merge_request_event" && $CI_COMMIT_TAG == null' + deploy-stg: extends: .deploy-stg