File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 8686 fi
8787
8888 - name : Build and push image (latest version)
89+ id : build_latest
8990 if : steps.version.outputs.is_latest == 'true'
9091 uses : docker/build-push-action@v6
9192 with :
@@ -100,6 +101,7 @@ jobs:
100101 ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
101102
102103 - name : Build and push image (none latest version)
104+ id : build_non_latest
103105 if : steps.version.outputs.is_latest == 'false'
104106 uses : docker/build-push-action@v6
105107 with :
@@ -120,10 +122,19 @@ jobs:
120122 - name : Generate installation manifest
121123 run : |
122124 GIT_SHA=$(git rev-parse --short HEAD)
125+
126+ # Use digest from whichever build step ran (latest or non-latest)
127+ if [ "${{ steps.version.outputs.is_latest }}" == "true" ]; then
128+ IMAGE_DIGEST="${{ steps.build_latest.outputs.digest }}"
129+ else
130+ IMAGE_DIGEST="${{ steps.build_non_latest.outputs.digest }}"
131+ fi
132+
123133 make build-installer \
124- IMG=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.full } } \
134+ IMG=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}@${IMAGE_DIGEST } \
125135 VERSION_LABEL=v${{ steps.version.outputs.full }} \
126136 GIT_SHA_LABEL=${GIT_SHA}
137+
127138 mv dist/install.yaml func-operator.yaml
128139
129140 - name : Create GitHub Release
You can’t perform that action at this time.
0 commit comments