Security Scan (Scheduled) #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Security Scan (Scheduled) | |
| on: | |
| schedule: | |
| - cron: '0 2 * * 1' # Every Monday at 02:00 UTC | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| security-events: write | |
| jobs: | |
| trivy-scan: | |
| name: Trivy Full Scan | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Trivy — filesystem scan | |
| uses: aquasecurity/trivy-action@0.28.0 | |
| with: | |
| scan-type: fs | |
| scan-ref: . | |
| format: sarif | |
| output: trivy-fs.sarif | |
| severity: CRITICAL,HIGH,MEDIUM | |
| - name: Upload SARIF | |
| uses: github/codeql-action/upload-sarif@v3 | |
| if: always() | |
| with: | |
| sarif_file: trivy-fs.sarif | |
| - name: Trivy — config scan | |
| uses: aquasecurity/trivy-action@0.28.0 | |
| with: | |
| scan-type: config | |
| scan-ref: . | |
| format: table | |
| severity: CRITICAL,HIGH |