Skip to content

Commit

Permalink
fix: another attempt at changing trivy
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-bcgov committed Sep 12, 2024
1 parent 6509e19 commit d1fe540
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/trivy-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,17 +28,22 @@ jobs:
run: mvn -ntp -DskipTests -Popenshift clean package

- name: Build an image from Dockerfile
env:
COMPOSE_DOCKER_CLI_BUILD: 1
DOCKER_BUILDKIT: 1
CONTEXT: .
run: |
docker build -t bc-paris-api:${{ github.sha }} .
docker build -t bc-paris-api:${{ github.sha }} ${CONTEXT}
#Run Vulnerability Scan usinig Trivy scanner
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
with:
scan-type: 'image'
image-ref: 'bc-paris-api:${{ github.sha }}'
format: 'sarif'
output: 'trivy-results.sarif'
exit-code: '0'
exit-code: '1'
ignore-unfixed: true
severity: 'HIGH,CRITICAL'

Expand Down

0 comments on commit d1fe540

Please sign in to comment.