Skip to content

Vulnerability Scan

Vulnerability Scan #89

name: "Vulnerability Scan"
on:
schedule:
- cron: "0 0 * * *"
env:
# temporary workaround for trivy db update issue
# https://github.com/aquasecurity/trivy/discussions/7538#discussioncomment-10741936
TRIVY_DB_REPOSITORY: public.ecr.aws/aquasecurity/trivy-db:2
jobs:
trivy:
strategy:
matrix:
image_name: [
"backenddevelopersltd/compute-horde-miner:v0-latest",
"backenddevelopersltd/compute-horde-miner-runner:v0-latest",
"backenddevelopersltd/compute-horde-miner-nginx:v0-latest",
"backenddevelopersltd/compute-horde-validator:v0-latest",
"backenddevelopersltd/compute-horde-validator-runner:v0-latest",
"backenddevelopersltd/compute-horde-validator-nginx:v0-latest",
"backenddevelopersltd/compute-horde-executor:v0-latest",
"backenddevelopersltd/compute-horde-job:v0-latest",
"backenddevelopersltd/compute-horde-job:v1-latest",
]
runs-on: ubuntu-latest
steps:
- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@0.24.0
with:
image-ref: "${{ matrix.image_name }}"
scanners: "vuln"
severity: 'CRITICAL,HIGH,MEDIUM'
limit-severities-for-sarif: true
ignore-unfixed: true
format: 'sarif'
output: 'trivy-results.sarif'
- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: 'trivy-results.sarif'