Skip to content

Commit 66500df

Browse files
committed
Fix GH Action so it can run locally and on GH
1 parent 13cae2c commit 66500df

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

.actrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
-P ubuntu-latest=ghcr.io/catthehacker/ubuntu:act-latest
2+

.github/workflows/build.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,22 @@ jobs:
2121
with:
2222
distribution: 'temurin'
2323
java-version: ${{ matrix.jdk }}
24+
- name: Install Maven
25+
run: |
26+
apt-get update
27+
apt-get install -y maven
2428
- name: Cache Maven packages
2529
uses: actions/cache@v4.2.3
2630
with:
2731
path: ~/.m2
2832
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
2933
restore-keys: ${{ runner.os }}-m2
34+
- name: Cache OWASP NVD data
35+
uses: actions/cache@v4.2.3
36+
with:
37+
path: ~/.m2/repository/org/owasp/dependency-check-data
38+
key: owasp-nvd-cache-${{ runner.os }}
39+
restore-keys: |
40+
owasp-nvd-cache-
3041
- name: Build with Maven
3142
run: mvn -B -U verify

pom.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,9 @@
246246
<groupId>org.owasp</groupId>
247247
<artifactId>dependency-check-maven</artifactId>
248248
<version>12.1.3</version>
249+
<configuration>
250+
<nvdApiKey>a1c5057d-457c-4e4f-959d-13c98786a664</nvdApiKey>
251+
</configuration>
249252
<executions>
250253
<execution>
251254
<goals>

0 commit comments

Comments
 (0)