diff --git a/.github/trivy.yml b/.github/trivy.yml new file mode 100644 index 000000000..8ac22e266 --- /dev/null +++ b/.github/trivy.yml @@ -0,0 +1,26 @@ +timeout: 10m +format: json +dependency-tree: true +list-all-pkgs: true +exit-code: 1 +output: result.json +severity: + - HIGH + - CRITICAL +scan: + skip-dirs: + .settings + .m2 + docs + infrastructure + target + vro-types + + scanners: + - vuln + - secret +vulnerability: + type: + - os + - library + ignore-unfixed: true diff --git a/.github/workflows/trivy.yml b/.github/workflows/trivy.yml new file mode 100644 index 000000000..1032ff132 --- /dev/null +++ b/.github/workflows/trivy.yml @@ -0,0 +1,20 @@ +name: build +on: + push: + branches: + - main + pull_request: +jobs: + build: + name: Build + runs-on: ubuntu-22.04 + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Run Trivy vulnerability scanner in fs mode + uses: aquasecurity/trivy-action@0.28.0 + with: + scan-type: 'fs' + scan-ref: '.' + trivy-config: .github/trivy.yml