File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed
Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 2323 # Ensure that tests pass before publishing a new image.
2424 build-and-push-ci :
2525 runs-on : ubuntu-latest
26+ permissions :
27+ contents : read
28+ security-events : write
2629 steps : # Assign context variable for various action contexts (tag, main, CI)
2730 - name : Assigning CI context
2831 if : github.head_ref != '' && github.head_ref != 'main' && !startsWith(github.ref, 'refs/tags/v')
@@ -169,3 +172,19 @@ jobs:
169172 sourcePath: ''
170173 uri: https://api.github.com/repos/trustyai-explainability/trustyai-service-operator-ci/tarball/operator-${{ env.TAG }}
171174 ```
175+ - name : Trivy scan
176+ uses :
aquasecurity/[email protected] 177+ with :
178+ scan-type : ' image'
179+ image-ref : " ${{ env.IMAGE_NAME }}:${{ env.TAG }}"
180+ format : ' sarif'
181+ output : ' trivy-results.sarif'
182+ severity : ' MEDIUM,HIGH,CRITICAL'
183+ exit-code : ' 0'
184+ ignore-unfixed : false
185+ vuln-type : ' os,library'
186+
187+ - name : Update Security tab
188+ uses : github/codeql-action/upload-sarif@v3
189+ with :
190+ sarif_file : ' trivy-results.sarif'
You can’t perform that action at this time.
0 commit comments