Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(ci): update image promotion vars #211

Merged
merged 4 commits into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions .github/workflows/merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ jobs:
oc_token: ${{ secrets.OC_TOKEN }}
overwrite: ${{ matrix.overwrite }}
parameters:
-p ZONE=test -p NAME=${{ github.event.repository.name }}
-p PROMOTE=${{ github.repository }}/${{ matrix.name }}:${{ needs.vars.outputs.pr }}
-p ZONE=test -p TAG=${{ needs.vars.outputs.pr }}
-p S3_SECRETKEY=${{ secrets.S3_SECRETKEY }}
${{ matrix.parameters }}
verification_path: ${{ matrix.verification_path }}
Expand Down Expand Up @@ -87,8 +86,7 @@ jobs:
oc_token: ${{ secrets.OC_TOKEN }}
overwrite: ${{ matrix.overwrite }}
parameters:
-p ZONE=prod -p NAME=${{ github.event.repository.name }}
-p PROMOTE=${{ github.repository }}/${{ matrix.name }}:${{ needs.vars.outputs.pr }}
-p ZONE=prod -p TAG=${{ needs.vars.outputs.pr }}
-p S3_SECRETKEY=${{ secrets.S3_SECRETKEY }}
${{ matrix.parameters }}
verification_path: ${{ matrix.verification_path }}
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/pr-open.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,7 @@ jobs:
overwrite: ${{ matrix.overwrite }}
penetration_test: false
parameters:
-p ZONE=${{ github.event.number }} -p NAME=${{ github.event.repository.name }}
-p PROMOTE=${{ github.repository }}/${{ matrix.name }}:${{ github.event.number }}
-p ZONE=${{ github.event.number }} -p TAG=${{ github.event.number }}
-p VITE_QUESTIONS_API_KEY=${{ secrets.VITE_QUESTIONS_API_KEY }}
-p MIN_REPLICAS=1 -p MAX_REPLICAS=2 ${{ matrix.parameters }}
-p S3_SECRETKEY=${{ secrets.S3_SECRETKEY }}
Expand Down
8 changes: 4 additions & 4 deletions backend/openshift.deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ parameters:
- name: ZONE
description: Deployment zone, e.g. pr-### or prod
required: true
- name: TAG
description: Image tag; e.g. PR number, latest or prod
required: true
- name: DOMAIN
value: apps.silver.devops.gov.bc.ca
- name: CPU_REQUEST
Expand Down Expand Up @@ -40,9 +43,6 @@ parameters:
- name: ORG
description: Organization name, e.g. bcgov
value: bcgov
- name: PROMOTE
description: Image (namespace/name:tag) to promote/import
value: bcgov/nr-results-exam/backend:test
- name: CHES_TOKEN_URL
value: "https://test.loginproxy.gov.bc.ca/auth/realms/comsvcauth/protocol/openid-connect/token"
- name: CHES_CLIENT_ID
Expand Down Expand Up @@ -116,7 +116,7 @@ objects:
deployment: "${NAME}-${ZONE}-${COMPONENT}"
spec:
containers:
- image: ${REGISTRY}/${ORG}/${NAME}/${COMPONENT}:${ZONE}
- image: ${REGISTRY}/${ORG}/${NAME}/${COMPONENT}:${TAG}
imagePullPolicy: Always
name: "${NAME}"
env:
Expand Down
8 changes: 4 additions & 4 deletions frontend/openshift.deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ parameters:
- name: ZONE
description: Deployment zone, e.g. pr-### or prod
required: true
- name: TAG
description: Image tag; e.g. PR number, latest or prod
required: true
- name: DOMAIN
value: apps.silver.devops.gov.bc.ca
- name: CPU_REQUEST
Expand All @@ -32,9 +35,6 @@ parameters:
- name: ORG
description: Organization name, e.g. bcgov
value: bcgov
- name: PROMOTE
description: Image (namespace/name:tag) to promote/import
value: bcgov/nr-results-exam/frontend:prod
- name: LOG_LEVEL
description: Caddy logging level DEBUG, INFO, WARN, ERROR, PANIC, and FATAL (https://github.com/caddyserver/caddy/blob/master/logging.go)
value: "info"
Expand Down Expand Up @@ -69,7 +69,7 @@ objects:
deployment: "${NAME}-${ZONE}-${COMPONENT}"
spec:
containers:
- image: ${REGISTRY}/${ORG}/${NAME}/${COMPONENT}:${ZONE}
- image: ${REGISTRY}/${ORG}/${NAME}/${COMPONENT}:${TAG}
securityContext:
capabilities:
add: ["NET_BIND_SERVICE"]
Expand Down
Loading