File tree Expand file tree Collapse file tree 5 files changed +29
-4
lines changed
Expand file tree Collapse file tree 5 files changed +29
-4
lines changed Original file line number Diff line number Diff line change 1818
1919permissions :
2020 contents : read # for actions/checkout to fetch code
21+ id-token : write
2122 security-events : write # for github/codeql-action/upload-sarif to upload SARIF results
2223 actions : read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
2324
5253 uses : github/codeql-action/upload-sarif@v3
5354 with :
5455 sarif_file : ${{ steps.scan.outputs.sarif }}
56+
57+ - name : Upload alerts file as a workflow artifact
58+ uses : actions/upload-artifact@v4
59+ with :
60+ name : alerts
61+ path : ${{ steps.scan.outputs.sarif }}
Original file line number Diff line number Diff line change 1818
1919permissions :
2020 contents : read # for actions/checkout to fetch code
21+ id-token : write
2122 security-events : write # for github/codeql-action/upload-sarif to upload SARIF results
2223 actions : read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
2324
4748 if : always()
4849 with :
4950 sarif_file : " trivy-results.sarif"
51+
52+ - name : Upload alerts file as a workflow artifact
53+ uses : actions/upload-artifact@v4
54+ with :
55+ name : alerts
56+ path : " trivy-results.sarif"
57+
Original file line number Diff line number Diff line change 3737 image : " ${{ env.imageName }}:${{ env.tag }}"
3838 artifact-name : image.spdx.json
3939 dependency-snapshot : true
40+
41+ - name : SBOM upload
42+ uses :
advanced-security/[email protected] 43+ with :
44+ filePath : " image.spdx.json"
Original file line number Diff line number Diff line change 22
33name : SCA - Microsoft SBOM Tool
44
5- on :
6- workflow_dispatch :
5+ on :
6+ push :
7+ branches : [main]
78
89env :
910 SRC_PROJECT_PATH : ' /webapp01/webapp01.csproj'
3738 - name : Upload a Build Artifact
3839 uses : actions/upload-artifact@v4
3940 with :
40- path : buildOutput
41+ path : buildOutput
42+
43+ - name : SBOM upload
44+ uses :
advanced-security/[email protected] 45+ with :
46+ filePath : " _manifest/spdx_2.2/"
Original file line number Diff line number Diff line change 22
33# This stage is used when running from VS in fast mode (Default for Debug configuration)
44FROM mcr.microsoft.com/dotnet/aspnet:9.0 AS base
5- USER $APP_UID
65WORKDIR /app
76EXPOSE 8080
87EXPOSE 8081
You can’t perform that action at this time.
0 commit comments