Skip to content

Commit cbb0185

Browse files
committed
Scan puhed images
1 parent ecf19d7 commit cbb0185

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

.github/workflows/docker-build-push.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
steps:
3030
- name: Checkout code
3131
uses: actions/checkout@v6.0.2
32-
32+
3333
- name: Set up Docker Buildx
3434
uses: docker/setup-buildx-action@v4
3535

@@ -48,3 +48,13 @@ jobs:
4848
push: true
4949
platforms: linux/amd64,linux/arm64
5050
tags: ghcr.io/${{ github.repository_owner }}/${{ matrix.app.name }}:${{ inputs.image-tag }}
51+
52+
- name: Scan pushed image with Trivy
53+
uses: aquasecurity/trivy-action@0.33.1
54+
with:
55+
scan-type: image
56+
image-ref: ghcr.io/${{ github.repository_owner }}/${{ matrix.app.name }}:${{ inputs.image-tag }}
57+
scanners: vuln,secret
58+
severity: HIGH,CRITICAL
59+
ignore-unfixed: true
60+
exit-code: "1"

0 commit comments

Comments
 (0)