Skip to content

Commit

Permalink
Merge pull request #527 from thomasferrandiz/add-trivy-check
Browse files Browse the repository at this point in the history
Add trivy vulnerability scanner build step
  • Loading branch information
dougbtv authored Dec 12, 2024
2 parents 9bfa52f + 8ff60f5 commit e31bb2c
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/image-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,22 @@ jobs:
push: false
tags: ghcr.io/${{ github.repository }}:latest-amd64
file: Dockerfile

- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@0.28.0
with:
image-ref: ghcr.io/${{ github.repository }}:latest-amd64
ignore-unfixed: true
vuln-type: 'os,library'
severity: 'CRITICAL,HIGH'
format: 'sarif'
output: 'trivy-results.sarif'

- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v3
if: always()
with:
sarif_file: 'trivy-results.sarif'

build-openshift:
name: Image build/openshift
Expand Down

0 comments on commit e31bb2c

Please sign in to comment.