mirror of
https://github.com/rocky-linux/sig-cloud-instance-images.git
synced 2024-12-18 15:18:35 +00:00
Upload scan results to github security tab
This commit is contained in:
parent
d1b15e475f
commit
81905fbe8a
11
.github/workflows/scan.yml
vendored
11
.github/workflows/scan.yml
vendored
@ -6,7 +6,7 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
scan:
|
scan:
|
||||||
name: Scan
|
name: Scan for Security Vulnerabilities
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
@ -16,8 +16,15 @@ jobs:
|
|||||||
uses: aquasecurity/trivy-action@master
|
uses: aquasecurity/trivy-action@master
|
||||||
with:
|
with:
|
||||||
image-ref: 'docker.io/library/rockylinux:8'
|
image-ref: 'docker.io/library/rockylinux:8'
|
||||||
format: 'table'
|
format: 'sarif'
|
||||||
|
output: 'trivy-results.sarif'
|
||||||
exit-code: '1'
|
exit-code: '1'
|
||||||
ignore-unfixed: true
|
ignore-unfixed: true
|
||||||
vuln-type: 'os,library'
|
vuln-type: 'os,library'
|
||||||
severity: 'CRITICAL,HIGH'
|
severity: 'CRITICAL,HIGH'
|
||||||
|
|
||||||
|
- name: Upload Trivy scan results to GitHub Security tab
|
||||||
|
uses: github/codeql-action/upload-sarif@v1
|
||||||
|
if: always()
|
||||||
|
with:
|
||||||
|
sarif_file: 'trivy-results.sarif'
|
||||||
|
Loading…
Reference in New Issue
Block a user