Skip to content

Commit 03c98a0

Browse files
committed
Move CVE cache to separate PR
1 parent e0c0d02 commit 03c98a0

File tree

2 files changed

+3
-37
lines changed

2 files changed

+3
-37
lines changed

.github/workflows/fosstars-report.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,6 @@ jobs:
2222
distribution: "temurin"
2323
java-version: ${{ env.JAVA_VERSION }}
2424
cache: 'maven'
25-
- name: Restore CVE Database
26-
uses: actions/cache/restore@v4
27-
with:
28-
path: ~/.m2/repository/org/owasp/dependency-check-data
29-
key: cve-db
30-
fail-on-cache-miss: true
3125
- name: "Build SDK"
3226
run: |
3327
MVN_ARGS="${{ env.MVN_MULTI_THREADED_ARGS }} clean install -DskipTests -DskipFormatting"

.github/workflows/update-owasp-db.yaml

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,9 @@ name: Update Vulnerability Database
33
on:
44
workflow_dispatch:
55
schedule:
6-
- cron: '17 5 * * *' # use a somewhat random time to avoid producing load spikes on the GH actions infrastructure
6+
- cron: '46 20 * * 2' # use a somewhat random time to avoid producing load spikes on the GH actions infrastructure
77

88
env:
9-
CVE_CACHE_REF: refs/heads/main
109
CVE_CACHE_KEY: cve-db
1110
CVE_CACHE_DIR: ~/.m2/repository/org/owasp/dependency-check-data
1211

@@ -17,32 +16,5 @@ jobs:
1716
contents: write
1817
steps:
1918
- uses: actions/checkout@v4
20-
with:
21-
ref: ${{ env.CVE_CACHE_REF }}
22-
- name: Restore Existing Cache
23-
uses: actions/cache/restore@v4
24-
with:
25-
path: ${{ env.CVE_CACHE_DIR }}
26-
key: ${{ env.CVE_CACHE_KEY }}
27-
28-
- name: Run Maven Plugin
29-
run: |
30-
mvn org.owasp:dependency-check-maven:10.0.4:update-only -DnvdMaxRetryCount=10 -DnvdApiDelay=15000 -DconnectionTimeout=60000
31-
env:
32-
NVD_API_KEY: ${{ secrets.NVD_API_KEY }}
33-
34-
- name: Delete Cache
35-
run: |
36-
CACHE_IDS=$(gh cache list --key "${{ env.CVE_CACHE_KEY }}" --ref "${{ env.CVE_CACHE_REF }}" --json id | jq -r '.[] | .id')
37-
for CACHE_ID in $CACHE_IDS; do
38-
echo "Deleting cache with ID: $CACHE_ID"
39-
gh cache delete "${CACHE_ID}"
40-
done
41-
env:
42-
GH_TOKEN: ${{ secrets.CLOUD_SDK_AT_SAP_ALL_ACCESS_PAT }}
43-
44-
- name: Cache CVE Database
45-
uses: actions/cache/save@v4
46-
with:
47-
path: ${{ env.CVE_CACHE_DIR }}
48-
key: ${{ env.CVE_CACHE_KEY }}
19+
- name: Dummy
20+
run: echo "Not implemented yet"

0 commit comments

Comments
 (0)