chore(deps): update aquasecurity/trivy-action action to v0.12.0 #3
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Security Scan | |
on: | |
push: | |
branches: | |
- master | |
- main | |
- renovate/** | |
pull_request: | |
schedule: | |
- cron: "0 3 * * *" | |
jobs: | |
trivy: | |
name: Trivy security scan | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Run Trivy vulnerability scanner in repo mode | |
uses: aquasecurity/[email protected] | |
if: ${{ ! github.event.schedule }} # Do not run inline checks when running periodically | |
with: | |
scan-type: fs | |
ignore-unfixed: true | |
exit-code: 1 | |
severity: 'HIGH,CRITICAL' | |
skip-dirs: 'build' | |
# test private key | |
skip-files: 'tests/integration/tls_cert/redis.key' | |
- name: Run Trivy vulnerability scanner sarif output | |
uses: aquasecurity/[email protected] | |
if: ${{ github.event.schedule }} # Generate sarif when running periodically | |
with: | |
scan-type: fs | |
ignore-unfixed: true | |
severity: 'HIGH,CRITICAL' | |
format: 'template' | |
template: '@/contrib/sarif.tpl' | |
output: 'trivy-results.sarif' | |
skip-dirs: 'build' | |
# test private key | |
skip-files: 'tests/integration/tls_cert/redis.key' | |
- name: Upload Trivy scan results to GitHub Security tab | |
uses: github/codeql-action/upload-sarif@v2 | |
if: ${{ github.event.schedule }} # Upload sarif when running periodically | |
with: | |
sarif_file: 'trivy-results.sarif' |