Fix deploy jobs to only run when dependencies succeed

Change 'when: always' to 'when: on_success' in deploy rules.
'when: always' was overriding the needs behavior, causing deploys
to run even when build_image or other dependencies failed.
This commit is contained in:
Mondo Diaz
2026-01-15 20:31:13 +00:00
parent 57e26c1cd9
commit e6826dbfcb

View File

@@ -256,7 +256,7 @@ deploy_stage:
agent: esv/bsf/bsf-integration/orchard/orchard-mvp:orchard-stage agent: esv/bsf/bsf-integration/orchard/orchard-mvp:orchard-stage
rules: rules:
- if: '$CI_COMMIT_BRANCH == "main"' - if: '$CI_COMMIT_BRANCH == "main"'
when: always when: on_success
# Deploy feature branch to dev namespace # Deploy feature branch to dev namespace
deploy_feature: deploy_feature:
@@ -295,7 +295,7 @@ deploy_feature:
agent: esv/bsf/bsf-integration/orchard/orchard-mvp:orchard agent: esv/bsf/bsf-integration/orchard/orchard-mvp:orchard
rules: rules:
- if: '$CI_COMMIT_BRANCH && $CI_COMMIT_BRANCH != "main"' - if: '$CI_COMMIT_BRANCH && $CI_COMMIT_BRANCH != "main"'
when: always when: on_success
# Cleanup feature branch deployment # Cleanup feature branch deployment
cleanup_feature: cleanup_feature: