Skip to content

Commit

Permalink
Merge pull request #312 from zillow/yunw/AIP-8740-review-branch-sandbox
Browse files Browse the repository at this point in the history
Test non-default branches in sandbox
  • Loading branch information
cloudw authored Sep 4, 2024
2 parents 11967b2 + 77b0baa commit 5922dce
Showing 1 changed file with 23 additions and 6 deletions.
29 changes: 23 additions & 6 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ variables:
# Run on the Internal cluster only on commit.
# We run the tests via the integration test framework for Non-Prod/Prod.
DEPLOY_INTERNAL: "true"
DEPLOY_REVIEW: "false"
DEPLOY_REVIEW: "true"
DEPLOY_STAGE: "false"
DEPLOY_PROD: "false"
DEPLOY_SANDBOX: "false"
Expand Down Expand Up @@ -139,16 +139,27 @@ build:publish:
rules:
- if: '$PUBLISH == "true"'

test:review:
extends:
- test:sandbox
rules:
- if: '$DEPLOY_REVIEW !~ /^true$/i'
when: never
- if: '$CI_COMMIT_BRANCH != $CI_DEFAULT_BRANCH'

test:sandbox:
extends:
extends:
- .devex_sandbox_eks
- .test
variables:
ARGO_RUN_URL_PREFIX: "https://argo-server.int.sandbox-k8s.zg-aip.net/"
METAFLOW_RUN_URL_PREFIX: "https://metaflow.int.sandbox-k8s.zg-aip.net"
METAFLOW_KUBERNETES_NAMESPACE: "metaflow-integration-testing-sandbox"
rules:
- if: '$DEPLOY_SANDBOX == "true"'
- if: '$DEPLOY_SANDBOX !~ /^true$/i'
when: never
- &rules-only-default-branch
if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH || ($CI_COMMIT_BRANCH != $CI_DEFAULT_BRANCH && $DEBUG_CI_DEFAULT_BRANCH =~ /^true$/i)'

test:internal:
extends:
Expand All @@ -159,7 +170,9 @@ test:internal:
METAFLOW_RUN_URL_PREFIX: "https://metaflow.int.dev-k8s.zg-aip.net"
METAFLOW_KUBERNETES_NAMESPACE: "metaflow-integration-testing-internal"
rules:
- if: '$DEPLOY_INTERNAL == "true"'
- if: '$DEPLOY_INTERNAL !~ /^true$/i'
when: never
- *rules-only-default-branch

test:nonprod:
extends:
Expand All @@ -170,7 +183,9 @@ test:nonprod:
METAFLOW_RUN_URL_PREFIX: "https://metaflow.int.stage-k8s.zg-aip.net"
METAFLOW_KUBERNETES_NAMESPACE: "metaflow-integration-testing-stage"
rules:
- if: '$DEPLOY_STAGE == "true"'
- if: '$DEPLOY_STAGE !~ /^true$/i'
when: never
- *rules-only-default-branch

test:prod:
extends:
Expand All @@ -181,4 +196,6 @@ test:prod:
METAFLOW_RUN_URL_PREFIX: "https://metaflow.int.prod-k8s.zg-aip.net"
METAFLOW_KUBERNETES_NAMESPACE: "metaflow-integration-testing-prod"
rules:
- if: '$DEPLOY_PROD == "true"'
- if: '$DEPLOY_PROD !~ /^true$/i'
when: never
- *rules-only-default-branch

0 comments on commit 5922dce

Please sign in to comment.