diff --git a/.github/workflows/trivy.yml b/.github/workflows/trivy.yml index 138b2f46c2..4f0ac49c1e 100644 --- a/.github/workflows/trivy.yml +++ b/.github/workflows/trivy.yml @@ -23,7 +23,7 @@ jobs: contents: read # for actions/checkout to fetch code security-events: write # for github/codeql-action/upload-sarif to upload SARIF results actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status - name: Trivy SAST Scan + name: Trivy config Scan runs-on: "ubuntu-20.04" steps: - name: Checkout code @@ -33,15 +33,15 @@ jobs: uses: aquasecurity/trivy-action@master with: scan-type: 'config' + hide-progress: true + format: 'sarif' + output: 'trivy-results.sarif' + exit-code: '1' + ignore-unfixed: true severity: 'CRITICAL,HIGH' - # ignore-unfixed: true - # format: 'sarif' - # output: 'trivy-results.sarif' - output: 'table' - # scanners: 'vuln,secret,config' - # - name: Upload Trivy scan results to GitHub Security tab - # uses: github/codeql-action/upload-sarif@v3 - # with: - # sarif_file: 'trivy-results.sarif' + - name: Upload Trivy scan results to GitHub Security tab + uses: github/codeql-action/upload-sarif@v3 + with: + sarif_file: 'trivy-results.sarif'