Skip to content

Commit

Permalink
build: add vulnerability scanners 🔒
Browse files Browse the repository at this point in the history
  • Loading branch information
robertrossmann committed Feb 22, 2024
1 parent b32b027 commit 49bcb30
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: "Tests"
name: Tests

on:
push:
Expand Down
35 changes: 35 additions & 0 deletions .github/workflows/vulnerability.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Vulnerability Scan

on:
pull_request:
push:
branches:
- 'master'
release:
types: [ published ]

jobs:
vulnerability:
name: Vulnerability Scan
runs-on: ubuntu-22.04
timeout-minutes: 5
permissions:
contents: read
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version-file: go.mod

- name: Install vulnerability scanners
run: |
go install golang.org/x/vuln/cmd/govulncheck@v1
go install github.com/google/osv-scanner/cmd/osv-scanner@v1
- name: Run govulncheck
run: govulncheck ./...

- name: Run OSV Scanner
run: osv-scanner -r .

0 comments on commit 49bcb30

Please sign in to comment.