-
-
Notifications
You must be signed in to change notification settings - Fork 188
43 lines (40 loc) · 1.26 KB
/
security-scan.yml
File metadata and controls
43 lines (40 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Security Scan for Docker Images
on:
schedule:
- cron: '0 0 * * 1'
workflow_dispatch:
permissions:
contents: read
security-events: write
jobs:
security-scan:
if: github.repository == 'SignalK/signalk-server'
name: Security Scan
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
os: [24.04, alpine]
node: [24.x]
include:
- os: 24.04
node: 24.x
image-tag: 'latest'
- os: alpine
node: 24.x
image-tag: 'latest-alpine'
steps:
- name: Checkout code
uses: actions/checkout@v6
- name: Run Trivy vulnerability scanner for Docker Image
uses: aquasecurity/trivy-action@0.35.0
with:
image-ref: 'ghcr.io/signalk/signalk-server:${{ matrix.image-tag }}'
format: 'sarif'
output: 'trivy-results-docker-node${{ matrix.node }}-${{ matrix.image-tag }}.sarif'
- name: Upload Trivy scan results to GitHub Security tab
uses: github/codeql-action/upload-sarif@v4
if: always()
with:
sarif_file: 'trivy-results-docker-node${{ matrix.node }}-${{ matrix.image-tag }}.sarif'
category: 'trivy-docker-node${{ matrix.node }}-${{ matrix.image-tag }}'