-
Notifications
You must be signed in to change notification settings - Fork 12
39 lines (38 loc) · 1.17 KB
/
cache.yml
File metadata and controls
39 lines (38 loc) · 1.17 KB
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
name: nvd cache
on:
schedule:
- cron: '0 11 * * *'
workflow_dispatch:
# Needed so we can run it manually
jobs:
build:
permissions:
contents: write
name: Update NVD API Cache
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: gh-pages
- uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
- name: update
env:
NVD_API_KEY: ${{ secrets.NVD_API_KEY }}
run: |
curl https://github.com/jeremylong/open-vulnerability-cli/releases/download/v9.0.0/vulnz-9.0.0.jar -s -L -o vulnz.jar
git reset --soft HEAD~1
ls -la .
java -jar vulnz.jar cve --cache --directory ./nvd_cache --requestCount=30 --debug --delay=8000 --maxRetry=40
rm vulnz.jar
git status
cat nvd_cache/cache.properties
git config user.email "actions@github.com"
git config user.name "GitHub Actions"
git add ./nvd_cache/
git commit -am 'chore: update'
git push origin gh-pages --force
cat nvd_cache/nvdcve-modified.meta