From 49317ac40abb8e9101960384a4127dd20bc5a8f9 Mon Sep 17 00:00:00 2001 From: Stefan Genov Date: Mon, 25 Nov 2024 13:06:27 +0200 Subject: [PATCH] chore(trivy): Added initial config Signed-off-by: Stefan Genov --- .github/trivy.yml | 26 ++++++++++++++++++++++++++ .github/workflows/trivy.yml | 20 ++++++++++++++++++++ 2 files changed, 46 insertions(+) create mode 100644 .github/trivy.yml create mode 100644 .github/workflows/trivy.yml 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