From 180207cd80b3d12cc9b8f132559ba0e6c0390a3e Mon Sep 17 00:00:00 2001 From: kalvinparker <106995826+kalvinparker@users.noreply.github.com> Date: Thu, 20 Nov 2025 22:56:50 +0000 Subject: [PATCH] chore(ci): pin aquasecurity/trivy-action and upload SARIF results --- .github/workflows/ci.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 00000000..b3a1a88c --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,34 @@ +name: Automated Security Gates + +on: + push: + branches: [ main, master ] + pull_request: + branches: [ main, master ] + +jobs: + build-and-scan: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v4 + + - name: Automated Vulnerability Scan (Trivy) + uses: aquasecurity/trivy-action@0.33.1 + with: + scan-type: 'fs' + ignore-unfixed: true + format: 'sarif' + output: 'trivy-results.sarif' + exit-code: '1' + + - name: Upload SARIF results to GitHub Code Scanning + uses: github/code-scanning-action/upload-sarif@v2 + with: + sarif_file: 'trivy-results.sarif' + + - name: Upload Trivy SARIF artifact + uses: actions/upload-artifact@v4 + with: + name: trivy-sarif + path: trivy-results.sarif