8282 uses : ./.github/workflows/_build-and-push.yml
8383 with :
8484 git-ref : ${{ github.event.workflow_run.head_sha || github.sha }}
85- env-name : dev
85+ env-name : ${{ inputs.environment }}
8686 tags : |
8787 type=raw,value=dev
8888 type=sha,prefix=dev-,format=short
@@ -101,7 +101,7 @@ jobs:
101101 needs : [build-dev]
102102 runs-on : ubuntu-latest
103103 timeout-minutes : 30
104- environment : dev
104+ environment : ${{ inputs.environment }}
105105 permissions :
106106 contents : read
107107 id-token : write
@@ -110,7 +110,7 @@ jobs:
110110
111111 - uses : ./.github/actions/deploy-env
112112 with :
113- gitops-env : dev
113+ gitops-env : ${ inputs.environment }
114114 image-tag : ${{ format('dev-{0}', needs.build-dev.outputs.sha-short) }}
115115 gitops-repo : ${{ github.repository_owner }}/mypythonproject1-gitops
116116 eks-cluster-name : mypythonproject1-dev-eks
@@ -151,7 +151,7 @@ jobs:
151151 uses : ./.github/workflows/_build-and-push.yml
152152 with :
153153 git-ref : ${{ github.event.workflow_run.head_sha || github.sha }}
154- env-name : staging
154+ env-name : ${{ inputs.environment }}
155155 tags : |
156156 type=raw,value=staging
157157 type=sha,prefix=staging-,format=short
@@ -170,7 +170,7 @@ jobs:
170170 needs : [build-staging]
171171 runs-on : ubuntu-latest
172172 timeout-minutes : 30
173- environment : staging
173+ environment : ${{ inputs.environment }}
174174 permissions :
175175 contents : read
176176 id-token : write
@@ -179,7 +179,7 @@ jobs:
179179
180180 - uses : ./.github/actions/deploy-env
181181 with :
182- gitops-env : staging
182+ gitops-env : ${ inputs.environment }
183183 image-tag : ${{ format('staging-{0}', needs.build-staging.outputs.sha-short) }}
184184 gitops-repo : ${{ github.repository_owner }}/mypythonproject1-gitops
185185 eks-cluster-name : mypythonproject1-staging-eks
@@ -255,7 +255,7 @@ jobs:
255255 uses : ./.github/workflows/_build-and-push.yml
256256 with :
257257 git-ref : ${{ github.ref }}
258- env-name : prod
258+ env-name : ${{ inputs.environment }}
259259 tags : |
260260 type=semver,pattern={{version}}
261261 type=semver,pattern={{major}}.{{minor}}
@@ -277,7 +277,7 @@ jobs:
277277 needs : [build-production]
278278 runs-on : ubuntu-latest
279279 timeout-minutes : 35
280- environment : prod
280+ environment : ${{ inputs.environment }}
281281 permissions :
282282 contents : read
283283 id-token : write
@@ -286,7 +286,7 @@ jobs:
286286
287287 - uses : ./.github/actions/deploy-env
288288 with :
289- gitops-env : prod
289+ gitops-env : ${{ inputs.environment }}
290290 image-tag : ${{ github.ref_name }}
291291 gitops-repo : ${{ github.repository_owner }}/mypythonproject1-gitops
292292 eks-cluster-name : mypythonproject1-prod-eks
0 commit comments