Skip to content

Commit fcea309

Browse files
authored
Merge pull request #1267 from nrkno/ci/trivy-db-image-rate-limiting
ci: use custom trivy database image
2 parents 56a5a6c + ccaeedb commit fcea309

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.github/workflows/node.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ jobs:
233233
if: steps.check-build-and-push.outputs.enable == 'true' && steps.check-ghcr.outputs.enable == 'true' && steps.ghcr-tag.outputs.tags != 0
234234
uses: aquasecurity/[email protected]
235235
env:
236-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
236+
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db
237237
with:
238238
image-ref: "${{ steps.trivy-image.outputs.image }}"
239239
format: "table"
@@ -383,6 +383,8 @@ jobs:
383383
- name: Trivy scanning
384384
if: steps.check-build-and-push.outputs.enable == 'true' && steps.check-ghcr.outputs.enable == 'true' && steps.ghcr-tag.outputs.tags != 0
385385
uses: aquasecurity/[email protected]
386+
env:
387+
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db
386388
with:
387389
image-ref: "${{ steps.trivy-image.outputs.image }}"
388390
format: "table"

.github/workflows/trivy.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,17 @@ jobs:
1414
steps:
1515
- name: Run Trivy vulnerability scanner (json)
1616
uses: aquasecurity/[email protected]
17+
env:
18+
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db
1719
with:
1820
image-ref: ghcr.io/nrkno/sofie-core-${{ matrix.image }}:latest
1921
format: json
2022
output: '${{ matrix.image }}-trivy-scan-results.json'
2123

2224
- name: Run Trivy vulnerability scanner (table)
2325
uses: aquasecurity/[email protected]
26+
env:
27+
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db
2428
with:
2529
image-ref: ghcr.io/nrkno/sofie-core-${{ matrix.image }}:latest
2630
output: '${{ matrix.image }}-trivy-scan-results.txt'
@@ -37,6 +41,8 @@ jobs:
3741
3842
- name: Run Trivy in GitHub SBOM mode and submit results to Dependency Graph
3943
uses: aquasecurity/[email protected]
44+
env:
45+
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db
4046
with:
4147
format: 'github'
4248
output: 'dependency-results-${{ matrix.image }}.sbom.json'

0 commit comments

Comments
 (0)