From db3e4cc1f27f028d6f4ad981edb5f8ad21b8a789 Mon Sep 17 00:00:00 2001 From: Pranc1ngPegasus Date: Sun, 6 Nov 2022 08:28:05 +0900 Subject: [PATCH] fix: trivy action config --- .github/workflows/trivy.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/trivy.yml b/.github/workflows/trivy.yml index 1d5d573..9aad808 100644 --- a/.github/workflows/trivy.yml +++ b/.github/workflows/trivy.yml @@ -7,17 +7,14 @@ jobs: trivy: name: Security check runs-on: ubuntu-latest - env: - IMAGE_NAME: docker.io/pranc1ngpegasus/go-template steps: - name: Checkout code uses: actions/checkout@v3 - - name: Build an image from Dockerfile - run: docker build -t ${{ env.IMAGE_NAME }}:${{ github.sha }} . - name: Run Trivy vulnerability scanner uses: aquasecurity/trivy-action@master with: - image-ref: '${{ env.IMAGE_NAME }}:${{ github.sha }}' + scan-type: 'fs' + scan-ref: '.' format: 'sarif' output: 'trivy-results.sarif' - name: Upload Trivy scan results to GitHub Security tab