fix(ci): authenticate trivy-action's github.com clone #44
@@ -66,6 +66,15 @@ jobs:
|
|||||||
# Dependency vulnerability scan (binary tool, invoked via official
|
# Dependency vulnerability scan (binary tool, invoked via official
|
||||||
# action — Trivy is a Go binary, not an npm package, so it cannot
|
# action — Trivy is a Go binary, not an npm package, so it cannot
|
||||||
# live in package.json scripts as cleanly as audit/lint do).
|
# live in package.json scripts as cleanly as audit/lint do).
|
||||||
|
#
|
||||||
|
# On cache miss (the act_runner cache server is currently
|
||||||
|
# unreachable from job containers — see infra/README.md "Cache
|
||||||
|
# server (deferred)"), the action falls back to `git clone
|
||||||
|
# https://github.com/aquasecurity/trivy` to fetch its install
|
||||||
|
# script. Without auth that hits github.com's 60 req/h anonymous
|
||||||
|
# rate limit and `git fetch` fails with "could not read Username".
|
||||||
|
# GITHUBCOM_TOKEN is the same zero-scope github.com PAT we use
|
||||||
|
# for Renovate (per docs/development.md "Dependency updates").
|
||||||
- uses: aquasecurity/trivy-action@master
|
- uses: aquasecurity/trivy-action@master
|
||||||
with:
|
with:
|
||||||
scan-type: fs
|
scan-type: fs
|
||||||
@@ -73,6 +82,8 @@ jobs:
|
|||||||
skip-dirs: node_modules
|
skip-dirs: node_modules
|
||||||
exit-code: '1'
|
exit-code: '1'
|
||||||
severity: 'CRITICAL,HIGH'
|
severity: 'CRITICAL,HIGH'
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUBCOM_TOKEN }}
|
||||||
# Secret scan, same reasoning (gitleaks is a Go binary).
|
# Secret scan, same reasoning (gitleaks is a Go binary).
|
||||||
- uses: gitleaks/gitleaks-action@v2
|
- uses: gitleaks/gitleaks-action@v2
|
||||||
env:
|
env:
|
||||||
|
|||||||
Reference in New Issue
Block a user