Skip to content

Commit 1d0b633

Browse files
committed
Hopefully speed up second run
1 parent daf66a8 commit 1d0b633

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

.github/workflows/trivyscan.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ jobs:
102102
run: sudo guestmount -a /mnt/images/${{ steps.manifest.outputs.image-name }}.qcow2 -i --ro -o allow_other './${{ steps.manifest.outputs.image-name }}'
103103

104104
- name: Run Trivy vulnerability scanner
105-
uses: aquasecurity/trivy-action@0.24.0
105+
uses: aquasecurity/trivy-action@v0.33.1
106106
with:
107107
scan-type: fs
108108
scan-ref: "${{ steps.manifest.outputs.image-name }}"
@@ -116,13 +116,13 @@ jobs:
116116
TRIVY_DB_REPOSITORY: ghcr.io/azimuth-cloud/trivy-db:2
117117

118118
- name: Upload Trivy scan results to GitHub Security tab
119-
uses: github/codeql-action/upload-sarif@v3
119+
uses: github/codeql-action/upload-sarif@v4
120120
with:
121121
sarif_file: "${{ steps.manifest.outputs.image-name }}.sarif"
122122
category: "${{ matrix.build }}"
123123

124124
- name: Fail if scan has CRITICAL vulnerabilities
125-
uses: aquasecurity/trivy-action@0.24.0
125+
uses: aquasecurity/trivy-action@v0.33.1
126126
with:
127127
scan-type: fs
128128
scan-ref: "${{ steps.manifest.outputs.image-name }}"
@@ -132,6 +132,8 @@ jobs:
132132
severity: 'CRITICAL'
133133
ignore-unfixed: true
134134
timeout: 15m
135+
# On a subsequent call to the action we know trivy is already installed so can skip this
136+
skip-setup-trivy: true
135137
env:
136138
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
137139
TRIVY_DB_REPOSITORY: ghcr.io/azimuth-cloud/trivy-db:2

0 commit comments

Comments
 (0)