diff --git a/.github/workflows/test-pr.yml b/.github/workflows/test-pr.yml index 03fff6c65..a09ee13bb 100644 --- a/.github/workflows/test-pr.yml +++ b/.github/workflows/test-pr.yml @@ -41,6 +41,11 @@ jobs: name: ${{ matrix.name }} runs-on: ${{ matrix.os }} steps: + # - name: Enable WSL on Windows for sbom + # if: runner.os == 'Windows' + # uses: Vampire/setup-wsl@v1 + # with: + # distribution: Alpine - uses: actions/checkout@v3 - name: Prepare Environment run: ${{ matrix.runs.prepare }} @@ -61,13 +66,14 @@ jobs: format: 'sarif' output: 'scan_dockerimage_result.sarif' severity: 'CRITICAL,HIGH' - - name: Upload Trivy scan results to GitHub Security tab + - name: Upload Trivy scan results to GitHub Security tab for Linux if: steps.scan.conclusion == 'success' uses: github/codeql-action/upload-sarif@v2 with: sarif_file: 'scan_dockerimage_result.sarif' - - name: Generate SBOM + - name: Generate SBOM for Linux uses: anchore/sbom-action@v0 + if: steps.scan.conclusion == 'success' with: image: '${{ matrix.meta.entries[0].tags[0] }}' format: 'cyclonedx-json'