mirror of
https://github.com/Dvorinka/Primora.git
synced 2026-10-28 15:51:23 +00:00
ci: run Trivy via container image, not the action
The trivy-action setup step downloads its binary through the unauthenticated GitHub API and dies to rate limits on shared runners. Running aquasec/trivy against the docker socket has no API dependency and is one line shorter. Authored By: TDvorak <[email protected]> Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
fe28902c4a
commit
fc79c57f7e
1 file changed
+9
-7
@@ -130,14 +130,16 @@ jobs:
|
||||
frontend) docker run --rm --entrypoint sh primora-frontend:test -c 'test -f /usr/share/nginx/html/index.html' ;;
|
||||
esac
|
||||
|
||||
# Trivy via its container image — the action's binary installer is
|
||||
# rate-limited by unauthenticated GitHub API calls on shared runners.
|
||||
- name: Scan ${{ matrix.app }} image
|
||||
uses: aquasecurity/[email protected]
|
||||
with:
|
||||
image-ref: primora-${{ matrix.app }}:test
|
||||
severity: CRITICAL,HIGH
|
||||
ignore-unfixed: true
|
||||
exit-code: '0'
|
||||
format: table
|
||||
run: >-
|
||||
docker run --rm
|
||||
-v /var/run/docker.sock:/var/run/docker.sock
|
||||
aquasec/trivy:0.65.0
|
||||
image --severity HIGH,CRITICAL --ignore-unfixed --exit-code 0
|
||||
--format table
|
||||
primora-${{ matrix.app }}:test
|
||||
|
||||
docker-publish:
|
||||
name: Publish edge images
|
||||
|
||||
Reference in new issue
Block a user