Skip to content

Commit 5392675

Browse files
committed
fix(ci): use correct image tag for Trivy scan
The vulnerability scan was attempting to scan :latest tag instead of the actual built image tagged with the commit SHA. This caused the scan to fail with 'trivy-results.sarif not found' error.
1 parent bed9161 commit 5392675

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

.github/workflows/build-push-greenhouse-image.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ jobs:
145145
- name: Run Trivy vulnerability scanner
146146
uses: aquasecurity/trivy-action@b6643a29fecd7f34b3597bc6acb0a98b03d33ff8 # 0.33.1
147147
with:
148-
image-ref: ${{ env.REGISTRY }}/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:latest
148+
image-ref: ${{ env.REGISTRY }}/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:${{ github.sha }}
149149
ignore-unfixed: true
150150
format: "sarif"
151151
output: "trivy-results.sarif"

0 commit comments

Comments
 (0)