File tree Expand file tree Collapse file tree 5 files changed +40
-16
lines changed Expand file tree Collapse file tree 5 files changed +40
-16
lines changed Original file line number Diff line number Diff line change 5959 - name : Deploy to Dockerhub
6060 env :
6161 DOCKERHUB_REPO : ${{ env.DOCKERHUB_REPO }}
62+ TAGS : ${{ steps.meta.outputs.tags }}
6263 run : |
6364 # deploy main
64- docker tag blurts-server ${{ steps.meta.outputs.tags }}
65- docker push ${{ steps.meta.outputs.tags }}
65+ docker tag blurts-server $TAGS
66+ docker push $TAGS
Original file line number Diff line number Diff line change @@ -68,13 +68,15 @@ jobs:
6868
6969 - name : Build and push Docker image to GAR
7070 id : build-and-push
71+ env :
72+ TAGS : ${{ steps.meta.outputs.tags }}
7173 uses : docker/build-push-action@v6
7274 with :
7375 context : .
7476 # Push is true to push to GAR after build
7577 push : true
7678 # Tags generated by the metadata action (only GAR tag)
77- tags : ${{ steps.meta.outputs.tags }}
79+ tags : ${{ env.TAGS }}
7880 # Pass build arguments
7981 build-args : |
8082 SENTRY_RELEASE=${{ github.sha }} # Use full SHA for Sentry release clarity
8789 cache-to : type=gha,mode=max
8890
8991 - name : Print Image URI
92+ env :
93+ TAGS : ${{ steps.meta.outputs.tags }}
9094 run : |
91- echo "Pushed GAR image: ${{ steps.meta.outputs.tags }}"
95+ echo "Pushed GAR image: $TAGS"
Original file line number Diff line number Diff line change @@ -84,16 +84,22 @@ jobs:
8484 tags : type=sha,format=short,prefix=
8585
8686 - name : Pull Docker image from GAR with commit tag
87- run : docker pull ${{ env.GAR_IMAGE_BASE }}:${{ steps.meta.outputs.version }}
87+ env :
88+ VERSION : ${{ steps.meta.outputs.version }}
89+ run : docker pull ${{ env.GAR_IMAGE_BASE }}:$VERSION
8890
8991 - name : Tag Docker image for Docker Hub with release tag
90- run : docker tag ${{ env.GAR_IMAGE_BASE }}:${{ steps.meta.outputs.version }} ${{ env.DOCKERHUB_IMAGE }}:${{ env.CURRENT_DATE }}
92+ env :
93+ VERSION : ${{ steps.meta.outputs.version }}
94+ run : docker tag ${{ env.GAR_IMAGE_BASE }}:$VERSION ${{ env.DOCKERHUB_IMAGE }}:${{ env.CURRENT_DATE }}
9195
9296 - name : Push Docker image to Docker Hub with release tag
9397 run : docker push ${{ env.DOCKERHUB_IMAGE }}:${{ env.CURRENT_DATE }}
9498
9599 - name : Tag Docker image for GAR with release tag
96- run : docker tag ${{ env.GAR_IMAGE_BASE }}:${{ steps.meta.outputs.version }} ${{ env.GAR_IMAGE_BASE }}:${{ env.CURRENT_DATE }}
100+ env :
101+ VERSION : ${{ steps.meta.outputs.version }}
102+ run : docker tag ${{ env.GAR_IMAGE_BASE }}:$VERSION ${{ env.GAR_IMAGE_BASE }}:${{ env.CURRENT_DATE }}
97103
98104 - name : Push Docker image to GAR with release tag
99105 run : docker push ${{ env.GAR_IMAGE_BASE }}:${{ env.CURRENT_DATE }}
Original file line number Diff line number Diff line change @@ -32,10 +32,14 @@ jobs:
3232 tags : type=sha,format=short,prefix=
3333
3434 - name : Pull Docker image with commit tag
35- run : docker pull ${{ steps.meta.outputs.tags }}
35+ env :
36+ TAGS : ${{ steps.meta.outputs.tags }}
37+ run : docker pull $TAGS
3638
3739 - name : Tag Docker image with release tag
38- run : docker tag ${{ steps.meta.outputs.tags }} mozilla/blurts-server:${{ github.ref_name }}
40+ env :
41+ TAGS : ${{ steps.meta.outputs.tags }}
42+ run : docker tag $TAGS mozilla/blurts-server:${{ github.ref_name }}
3943
4044 - name : Push Docker image with release tag
4145 run : docker push mozilla/blurts-server:${{ github.ref_name }}
Original file line number Diff line number Diff line change @@ -55,20 +55,29 @@ jobs:
5555 run : echo "name=${{ env.GAR_IMAGE_BASE }}:${{ github.ref_name }}" >> $GITHUB_OUTPUT
5656
5757 - name : Pull Docker image with commit tag from GAR
58+ env :
59+ TAGS : ${{ steps.meta.outputs.tags }}
5860 run : |
59- echo "Pulling ${{ steps.meta.outputs.tags }} "
60- docker pull ${{ steps.meta.outputs.tags }}
61+ echo "Pulling $TAGS "
62+ docker pull $TAGS
6163
6264 - name : Tag Docker image with release tag
65+ env :
66+ TAGS : ${{ steps.meta.outputs.tags }}
67+ NAME : ${{ steps.release_tag_info.outputs.name }}
6368 run : |
64- echo "Tagging ${{ steps.meta.outputs.tags }} as ${{ steps.release_tag_info.outputs.name }} "
65- docker tag ${{ steps.meta.outputs.tags }} ${{ steps.release_tag_info.outputs.name }}
69+ echo "Tagging $TAGS as $NAME "
70+ docker tag $TAGS $NAME
6671
6772 - name : Push Docker image with release tag to GAR
73+ env :
74+ NAME : ${{ steps.release_tag_info.outputs.name }}
6875 run : |
69- echo "Pushing ${{ steps.release_tag_info.outputs.name }} "
70- docker push ${{ steps.release_tag_info.outputs.name }}
76+ echo "Pushing $NAME "
77+ docker push $NAME
7178
7279 - name : Print Image URI
80+ env :
81+ NAME : ${{ steps.release_tag_info.outputs.name }}
7382 run : |
74- echo "Retagged and pushed GAR image: ${{ steps.release_tag_info.outputs.name }}"
83+ echo "Retagged and pushed GAR image: $NAME"
You can’t perform that action at this time.
0 commit comments