Skip to content

Commit 82eba1e

Browse files
committed
🔥(ci) force ci to fails if trivy fails
If trivy fails we must stop the CI to avoid publishing images with security issues.
1 parent 8c42599 commit 82eba1e

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

.github/workflows/docker-hub.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ on:
1111
pull_request:
1212
branches:
1313
- 'main'
14+
- 'ci/trivy-fails'
1415

1516
env:
1617
DOCKER_USER: 1001:127
@@ -38,7 +39,6 @@ jobs:
3839
with:
3940
docker-build-args: '--target backend-production -f Dockerfile'
4041
docker-image-name: 'docker.io/lasuite/impress-backend:${{ github.sha }}'
41-
continue-on-error: true
4242
-
4343
name: Build and push
4444
uses: docker/build-push-action@v6
@@ -72,7 +72,6 @@ jobs:
7272
with:
7373
docker-build-args: '-f src/frontend/Dockerfile --target frontend-production'
7474
docker-image-name: 'docker.io/lasuite/impress-frontend:${{ github.sha }}'
75-
continue-on-error: true
7675
-
7776
name: Build and push
7877
uses: docker/build-push-action@v6
@@ -106,8 +105,7 @@ jobs:
106105
uses: numerique-gouv/action-trivy-cache@main
107106
with:
108107
docker-build-args: '-f src/frontend/servers/y-provider/Dockerfile --target y-provider'
109-
docker-image-name: 'docker.io/lasuite/impress-frontend:${{ github.sha }}'
110-
continue-on-error: true
108+
docker-image-name: 'docker.io/lasuite/impress-y-provider:${{ github.sha }}'
111109
-
112110
name: Build and push
113111
uses: docker/build-push-action@v6

0 commit comments

Comments
 (0)