Skip to content

Commit

Permalink
feat: added trivy scanner
Browse files Browse the repository at this point in the history
  • Loading branch information
Filipe Forattini committed May 11, 2022
1 parent 83af4c3 commit 4e73142
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
13 changes: 13 additions & 0 deletions .github/workflows/_self-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,19 @@ jobs:
with:
args: --repo=https://github.com/${{github.repository}}

- name: Run Trivy scanner
uses: aquasecurity/trivy-action@master
with:
scan-type: fs
format: 'sarif'
severity: 'CRITICAL,HIGH'
output: 'trivy-results.sarif'

- name: Upload Trivy results
uses: github/codeql-action/upload-sarif@v1
with:
sarif_file: 'trivy-results.sarif'

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/service-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,12 +129,11 @@ jobs:
uses: aquasecurity/trivy-action@master
with:
scan-type: fs
input: /tmp/image-${{ matrix.node-version }}.tar
format: 'sarif'
severity: 'CRITICAL,HIGH'
output: 'trivy-results.sarif'

- name: Upload Trivy scan results to GitHub Security tab
- name: Upload Trivy results
uses: github/codeql-action/upload-sarif@v1
with:
sarif_file: 'trivy-results.sarif'
Expand Down

0 comments on commit 4e73142

Please sign in to comment.