Skip to content

Commit 00900fb

Browse files
authored
ci: update CI workflows and standardize Trivy config quotes (#4531)
- Update gin workflow to use v2.9 and add Go 1.26 to the matrix - Upgrade Trivy action to v0.34.0 in the scan workflow - Change all single quotes to double quotes in Trivy workflow configuration Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
1 parent 5260de6 commit 00900fb

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

.github/workflows/gin.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,14 @@ jobs:
2626
- name: Setup golangci-lint
2727
uses: golangci/golangci-lint-action@v9
2828
with:
29-
version: v2.6
29+
version: v2.9
3030
args: --verbose
3131
test:
3232
needs: lint
3333
strategy:
3434
matrix:
3535
os: [ubuntu-latest, macos-latest]
36-
go: ["1.24", "1.25"]
36+
go: ["1.24", "1.25", "1.26"]
3737
test-tags:
3838
[
3939
"",

.github/workflows/trivy-scan.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
- master
1010
schedule:
1111
# Run daily at 00:00 UTC
12-
- cron: '0 0 * * *'
12+
- cron: "0 0 * * *"
1313
workflow_dispatch: # Allow manual trigger
1414

1515
permissions:
@@ -29,28 +29,28 @@ jobs:
2929
- name: Run Trivy vulnerability scanner (source code)
3030
uses: aquasecurity/trivy-action@0.34.0
3131
with:
32-
scan-type: 'fs'
33-
scan-ref: '.'
34-
scanners: 'vuln,secret,misconfig'
35-
format: 'sarif'
36-
output: 'trivy-results.sarif'
37-
severity: 'CRITICAL,HIGH,MEDIUM'
32+
scan-type: "fs"
33+
scan-ref: "."
34+
scanners: "vuln,secret,misconfig"
35+
format: "sarif"
36+
output: "trivy-results.sarif"
37+
severity: "CRITICAL,HIGH,MEDIUM"
3838
ignore-unfixed: true
3939

4040
- name: Upload Trivy results to GitHub Security tab
4141
uses: github/codeql-action/upload-sarif@v4
4242
if: always()
4343
with:
44-
sarif_file: 'trivy-results.sarif'
44+
sarif_file: "trivy-results.sarif"
4545

4646
- name: Run Trivy scanner (table output for logs)
4747
uses: aquasecurity/trivy-action@0.34.0
4848
if: always()
4949
with:
50-
scan-type: 'fs'
51-
scan-ref: '.'
52-
scanners: 'vuln,secret,misconfig'
53-
format: 'table'
54-
severity: 'CRITICAL,HIGH,MEDIUM'
50+
scan-type: "fs"
51+
scan-ref: "."
52+
scanners: "vuln,secret,misconfig"
53+
format: "table"
54+
severity: "CRITICAL,HIGH,MEDIUM"
5555
ignore-unfixed: true
56-
exit-code: '1'
56+
exit-code: "1"

0 commit comments

Comments
 (0)