forked from teslims2/StellarKraal-
-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (27 loc) · 754 Bytes
/
Copy pathnpm-audit.yml
File metadata and controls
33 lines (27 loc) · 754 Bytes
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
name: npm audit
on:
schedule:
- cron: '0 8 * * 1' # Every Monday at 08:00 UTC
workflow_dispatch:
jobs:
audit:
name: npm audit (${{ matrix.dir }})
runs-on: ubuntu-latest
timeout-minutes: 5
strategy:
fail-fast: false
matrix:
dir: [backend, frontend]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: npm
cache-dependency-path: ${{ matrix.dir }}/package-lock.json
- name: Install dependencies
run: npm ci
working-directory: ${{ matrix.dir }}
- name: Run npm audit (fail on high/critical)
run: npm audit --audit-level=high
working-directory: ${{ matrix.dir }}