Skip to content

Vulnerability Scan #1195

Vulnerability Scan

Vulnerability Scan #1195

# GitHub Actions docs
# https://help.github.com/en/articles/about-github-actions
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
name: Vulnerability Scan
on:
schedule:
- cron: '0 12 * * *'
workflow_dispatch:
jobs:
scan:
name: Scan docker image with Trivy
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Build the Docker image
run: docker build . --file Dockerfile --tag symfony-flex-backend:master
- name: Scan image with trivy
uses: lazy-actions/gitrivy@v3
with:
image-ref: symfony-flex-backend:master
format: 'table'
exit-code: '1'
ignore-unfixed: true
vuln-type: 'os,library'
severity: 'CRITICAL,HIGH'