|
|
|
|
@@ -36,9 +36,68 @@ stages:
|
|
|
|
|
- analyze
|
|
|
|
|
- deploy
|
|
|
|
|
|
|
|
|
|
# Override Prosper template jobs to exclude tag pipelines
|
|
|
|
|
# Tags only run deploy_prod and smoke_test_prod (image already built on main)
|
|
|
|
|
build_image:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
test_image:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
hadolint:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
kics:
|
|
|
|
|
variables:
|
|
|
|
|
KICS_CONFIG: kics.config
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
secrets:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
app_deps_scan:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
cve_scan:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
app_sbom_analysis:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
cve_sbom_analysis:
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
# Override release job to wait for stage integration tests before creating tag
|
|
|
|
|
# This ensures the tag (which triggers prod deploy) is only created after stage passes
|
|
|
|
|
release:
|
|
|
|
|
needs: [integration_test_stage, changelog]
|
|
|
|
|
|
|
|
|
|
# Full integration test suite template (for feature/stage deployments)
|
|
|
|
|
# Runs the complete pytest integration test suite against the deployed environment
|
|
|
|
|
@@ -269,6 +328,10 @@ python_unit_tests:
|
|
|
|
|
coverage_format: cobertura
|
|
|
|
|
path: backend/coverage.xml
|
|
|
|
|
coverage: '/TOTAL.*\s+(\d+%)/'
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
# Run frontend tests
|
|
|
|
|
frontend_tests:
|
|
|
|
|
@@ -298,6 +361,10 @@ frontend_tests:
|
|
|
|
|
coverage_format: cobertura
|
|
|
|
|
path: frontend/coverage/cobertura-coverage.xml
|
|
|
|
|
coverage: '/All files[^|]*\|[^|]*\s+([\d\.]+)/'
|
|
|
|
|
rules:
|
|
|
|
|
- if: '$CI_COMMIT_TAG'
|
|
|
|
|
when: never
|
|
|
|
|
- when: on_success
|
|
|
|
|
|
|
|
|
|
# Shared deploy configuration
|
|
|
|
|
.deploy_template: &deploy_template
|
|
|
|
|
@@ -425,12 +492,11 @@ cleanup_feature:
|
|
|
|
|
# Deploy to production (version tags only)
|
|
|
|
|
deploy_prod:
|
|
|
|
|
stage: deploy
|
|
|
|
|
# For tag pipelines, most jobs don't run (trusting main was tested)
|
|
|
|
|
# We only need build_image to have the image available
|
|
|
|
|
needs: [build_image]
|
|
|
|
|
# For tag pipelines, no other jobs run - image was already built when commit was on main
|
|
|
|
|
needs: []
|
|
|
|
|
image: deps.global.bsf.tools/registry-1.docker.io/alpine/k8s:1.29.12
|
|
|
|
|
variables:
|
|
|
|
|
NAMESPACE: orch-prod-namespace
|
|
|
|
|
NAMESPACE: orch-namespace
|
|
|
|
|
VALUES_FILE: helm/orchard/values-prod.yaml
|
|
|
|
|
BASE_URL: $PROD_URL
|
|
|
|
|
before_script:
|
|
|
|
|
|