File tree Expand file tree Collapse file tree 3 files changed +30
-1
lines changed Expand file tree Collapse file tree 3 files changed +30
-1
lines changed Original file line number Diff line number Diff line change 11# Matched against repo root (asterisk)
2- * @mishraomp @DerekRoberts
2+ * @mishraomp @cberg-aot @ DerekRoberts
33
44# Matched against directories
55# /.github/workflows/ @mishraomp @DerekRoberts
Original file line number Diff line number Diff line change @@ -100,6 +100,25 @@ jobs:
100100 INSPECT="docker manifest inspect ghcr.io/${{ inputs.organization }}/${{ inputs.repository }}/${{ matrix.package }}"
101101 SOURCE=$(${INSPECT}:${{ inputs.tag_promote }} | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
102102 TARGET=$(${INSPECT}:${{ inputs.target }} | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
103+ if [ "${SOURCE}" != "${TARGET}" ]; then
104+ echo "ERROR: Tagging failed!"
105+ echo "RETRY=true" >> $GITHUB_ENV
106+ fi
107+
108+ - uses : shrink/actions-docker-registry-tag@v4
109+ if : env.RETRY == 'true'
110+ with :
111+ registry : ghcr.io
112+ repository : ${{ inputs.organization }}/${{ inputs.repository }}/${{ matrix.package }}
113+ target : ${{ inputs.target }}
114+ tags : ${{ inputs.tag_promote }}
115+
116+ - if : env.RETRY == 'true'
117+ run : |
118+ # Verify tagging after retry
119+ INSPECT="docker manifest inspect ghcr.io/${{ inputs.organization }}/${{ inputs.repository }}/${{ matrix.package }}"
120+ SOURCE=$(${INSPECT}:${{ inputs.tag_promote }} | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
121+ TARGET=$(${INSPECT}:${{ inputs.target }} | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
103122 if [ "${SOURCE}" != "${TARGET}" ]; then
104123 echo "ERROR: Tagging failed!"
105124 exit 1
Original file line number Diff line number Diff line change 3232 target : latest
3333 tags : ${{ github.event.number }}
3434
35+ - run : |
36+ # Verify tagging
37+ INSPECT="docker manifest inspect ghcr.io/${{ github.repository }}/${{ matrix.package }}"
38+ SOURCE=$(${INSPECT}:latest | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
39+ TARGET=$(${INSPECT}:${{ github.event.number }} | jq -r '.manifests[] | select(.platform.architecture=="amd64") | .digest')
40+ if [ "${SOURCE}" != "${TARGET}" ]; then
41+ echo "ERROR: Tagging failed!"
42+ exit 1
43+ fi
44+
3545 deploys :
3646 name : Deploys
3747 needs : [builds, validate]
You can’t perform that action at this time.
0 commit comments