Skip to content

Commit

Permalink
Trigger Trivy report for containers 3
Browse files Browse the repository at this point in the history
  • Loading branch information
simao-silva committed Nov 6, 2023
1 parent 3489029 commit 7eee597
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 20 deletions.
19 changes: 9 additions & 10 deletions .github/workflows/pr-alpine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,17 @@ jobs:
uses: aquasecurity/trivy-action@master
with:
image-ref: ${{ env.IMAGE_NAME }}:test-alpine
format: "sarif"
output: "trivy-alpine-image-scan.sarif"
format: "table"
exit-code: "1"
ignore-unfixed: true
vuln-type: "os,library"
severity: "MEDIUM,HIGH,CRITICAL"

- name: Upload Trivy scan results to GitHub Security
uses: github/codeql-action/upload-sarif@v2
with:
# Path to SARIF file relative to the root of the repository
sarif_file: trivy-alpine-image-scan.sarif
# Optional category for the results
# Used to differentiate multiple results for one commit
category: alpine-image-scan
# - name: Upload Trivy scan results to GitHub Security
# uses: github/codeql-action/upload-sarif@v2
# with:
# # Path to SARIF file relative to the root of the repository
# sarif_file: trivy-alpine-image-scan.sarif
# # Optional category for the results
# # Used to differentiate multiple results for one commit
# category: alpine-image-scan
19 changes: 9 additions & 10 deletions .github/workflows/pr-debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,18 +39,17 @@ jobs:
uses: aquasecurity/trivy-action@master
with:
image-ref: ${{ env.IMAGE_NAME }}:test-debian
format: "sarif"
output: "trivy-debian-image-scan.sarif"
format: "table"
exit-code: "1"
ignore-unfixed: true
vuln-type: "os,library"
severity: "MEDIUM,CRITICAL,HIGH"

- name: Upload Trivy scan results to GitHub Security
uses: github/codeql-action/upload-sarif@v2
with:
# Path to SARIF file relative to the root of the repository
sarif_file: trivy-debian-image-scan.sarif
# Optional category for the results
# Used to differentiate multiple results for one commit
category: debian-image-scan
# - name: Upload Trivy scan results to GitHub Security
# uses: github/codeql-action/upload-sarif@v2
# with:
# # Path to SARIF file relative to the root of the repository
# sarif_file: trivy-debian-image-scan.sarif
# # Optional category for the results
# # Used to differentiate multiple results for one commit
# category: debian-image-scan

0 comments on commit 7eee597

Please sign in to comment.