Skip to content

Commit 4693031

Browse files
authored
Merge pull request #1768 from di/add-zizmor
Add and configure zizmor
2 parents a2f3c3e + b63d8da commit 4693031

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

.github/workflows/zizmor.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# From https://woodruffw.github.io/zizmor/usage/#use-in-github-actions
2+
3+
name: GitHub Actions Security Analysis with zizmor 🌈
4+
5+
on:
6+
push:
7+
branches: ["main"]
8+
pull_request:
9+
branches: ["**"]
10+
11+
jobs:
12+
zizmor:
13+
name: zizmor latest via PyPI
14+
runs-on: ubuntu-latest
15+
permissions:
16+
security-events: write
17+
# required for workflows in private repositories
18+
contents: read
19+
actions: read
20+
steps:
21+
- name: Checkout repository
22+
uses: actions/checkout@v4
23+
with:
24+
persist-credentials: false
25+
26+
- name: Install the latest version of uv
27+
uses: astral-sh/setup-uv@v5
28+
29+
- name: Run zizmor 🌈
30+
run: uvx zizmor --format sarif source/guides/github-actions-ci-cd-sample/* > results.sarif
31+
env:
32+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
33+
34+
- name: Upload SARIF file
35+
uses: github/codeql-action/upload-sarif@v3
36+
with:
37+
sarif_file: results.sarif
38+
category: zizmor

0 commit comments

Comments
 (0)