chore(ci): ajoute un audit de sécurité des dépendances (npm audit, pip-audit)

This commit is contained in:
Valentin
2026-09-17 12:25:15 +02:00
parent 7913518c4b
commit f5cac1c2a8
2 changed files with 23 additions and 5 deletions
+3
View File
@@ -56,3 +56,6 @@ jobs:
# Le marqueur `integration` est exclu par défaut, donc aucune base n'est nécessaire ici. # Le marqueur `integration` est exclu par défaut, donc aucune base n'est nécessaire ici.
- name: Tests et couverture - name: Tests et couverture
run: uv run pytest --cov-fail-under=85 run: uv run pytest --cov-fail-under=85
- name: Audit de sécurité des dépendances
run: uv run --with pip-audit pip-audit
+20 -5
View File
@@ -36,13 +36,13 @@ jobs:
node-version: 24 node-version: 24
cache: npm cache: npm
cache-dependency-path: apps/frontend/package-lock.json cache-dependency-path: apps/frontend/package-lock.json
- run: npm ci - run: npm ci
working-directory: apps/frontend working-directory: apps/frontend
- run: npm run build - run: npm run build
working-directory: apps/frontend working-directory: apps/frontend
test: security-audit:
needs: build needs: build
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
@@ -52,7 +52,22 @@ jobs:
node-version: 24 node-version: 24
cache: npm cache: npm
cache-dependency-path: apps/frontend/package-lock.json cache-dependency-path: apps/frontend/package-lock.json
- run: npm ci - run: npm ci
working-directory: apps/frontend
- run: npm audit --audit-level=high
working-directory: apps/frontend
test:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: 24
cache: npm
cache-dependency-path: apps/frontend/package-lock.json
- run: npm ci
working-directory: apps/frontend working-directory: apps/frontend
- run: npm test -- --watch=false - run: npm test -- --watch=false
working-directory: apps/frontend working-directory: apps/frontend
@@ -70,7 +85,7 @@ jobs:
env: env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
# deploy: # deploy:
# runs-on: ubuntu-latest # runs-on: ubuntu-latest
# steps: # steps: