Skip to content

Commit

Permalink
Merge pull request #340 from arnested/govulncheck-sarif
Browse files Browse the repository at this point in the history
Use sarif output of golang.org/x/vuln/cmd/govulncheck
  • Loading branch information
arnested authored Jul 22, 2024
2 parents 04848e3 + 180961b commit c832b12
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,15 @@ jobs:
uses: WillAbides/setup-go-faster@v1.14.0
with:
go-version-file: go.mod
- name: Install govulncheck
run: go install golang.org/x/vuln/cmd/govulncheck@latest
- name: Run govulncheck
run: govulncheck ./...
- id: govulncheck
uses: golang/govulncheck-action@master
with:
govulncheck-action: go.mod
output-format: sarif
output-file: results.sarif
- name: Fix SARIF format
run: yq --inplace --output-format json '.runs |= map ({"results":[]} + .)' results.sarif
- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: results.sarif

0 comments on commit c832b12

Please sign in to comment.