cyberchef/.github/workflows/docker-build-daily.yml

39 lines
943 B
YAML

name: Daily Docker Build
on:
workflow_dispatch:
schedule:
- cron: "0 2 * * *"
jobs:
build-and-scan:
name: Build and scan Docker image (daily)
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build image from fresh base layers
run: |
docker buildx build \
--pull \
--load \
--tag cyberchef:${{ github.sha }} \
-f Dockerfile .
- name: Scan image for High/Critical issues (fails on detection)
uses: aquasecurity/trivy-action@0.24.0
with:
image-ref: cyberchef:${{ github.sha }}
format: table
vuln-type: "os,library"
severity: "CRITICAL,HIGH"
exit-code: "1"
ignore-unfixed: false