-
Notifications
You must be signed in to change notification settings - Fork 415
41 lines (40 loc) · 1.09 KB
/
govulncheck.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Nightly govulncheck
on:
push:
branches:
- 'shevchenko/govulncheck'
#on:
# push:
# branches:
# - main
# schedule:
# - cron: '00 00 * * *'
jobs:
govulncheck-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
repository: 'DataDog/dd-trace-go'
- name: Checkout Go
uses: actions/setup-go@v3
with:
go-version: '1.18'
- name: Install govulncheck
run: |
go install golang.org/x/vuln/cmd/govulncheck@latest
- name: Run govulncheck in packages
run: |
function check_results {
results=$(govulncheck $path | grep -Eo '\w+-\d+-\d+' | uniq)
if [ $(echo $results | wc -l) -gt 0 ]; then
echo "Found these vulnerabilities in $path:"
echo $results
exit 1
fi
}
path=./ddtrace/... check_results
path=./appsec/... check_results
path=./internal/... check_results
path=./contrib/... check_results
path=./profiler/... check_results