@@ -117,11 +117,11 @@ jobs:
117117 uses : docker/setup-qemu-action@68827325e0b33c7199eb31dd4e31fbe9023e06e3 # v3.0.0
118118 with :
119119 platforms : arm,arm64,ppc64le,s390x
120- if : ${{ steps.images_exist.outputs.target_exists != 'true' }}
120+ if : ${{ steps.images_exist.outputs.base_exists != 'true' || steps.images_exist.outputs. target_exists != 'true' }}
121121
122122 - name : Docker Buildx
123123 uses : docker/setup-buildx-action@d70bba72b1f3fd22344832f00baa16ece964efeb # v3.3.0
124- if : ${{ steps.images_exist.outputs.target_exists != 'true' }}
124+ if : ${{ steps.images_exist.outputs.base_exists != 'true' || steps.images_exist.outputs. target_exists != 'true' }}
125125
126126 - name : Build Base Container
127127 uses : docker/build-push-action@31159d49c0d4756269a0940a750801a1ea5d7003 # v6.1.0
@@ -196,17 +196,10 @@ jobs:
196196 mkdir -p "${{ inputs.image }}-results/"
197197 if : ${{ inputs.authenticated && steps.build-push.conclusion == 'success' }}
198198
199- - name : Extract image name for Scans
200- id : scan-tag
201- run : |
202- tag=$(echo $DOCKER_METADATA_OUTPUT_JSON | jq -r '[ .tags[] | select(contains("f5-gcs-7899"))] | .[0]')
203- echo "tag=$tag" >> $GITHUB_OUTPUT
204- if : ${{ inputs.authenticated && steps.build-push.conclusion == 'success' }}
205-
206199 - name : Run Trivy vulnerability scanner
207200 uses : aquasecurity/trivy-action@7c2007bcb556501da015201bcba5aa14069b74e2 # 0.23.0
208201 with :
209- image-ref : ${{ steps.scan-tag .outputs.tag }}
202+ image-ref : ${{ steps.meta .outputs.tags }}
210203 format : " sarif"
211204 output : " ${{ inputs.image }}-results/trivy.sarif"
212205 ignore-unfixed : " true"
@@ -224,7 +217,7 @@ jobs:
224217 uses : docker/scout-action@fc749439af4870e8f6feb592250ab728600d10a6 # v1.10.0
225218 with :
226219 command : cves,recommendations
227- image : ${{ steps.scan-tag .outputs.tag }}
220+ image : ${{ steps.meta .outputs.tags }}
228221 ignore-base : true
229222 only-fixed : true
230223 sarif-file : " ${{ inputs.image }}-results/scout.sarif"
0 commit comments