Fix CI workflow: actionlint install, zizmor, and permissions
All checks were successful
CI / backend-lint (pull_request) Successful in 9s
CI / actions-lint (pull_request) Successful in 15s
CI / frontend-lint (pull_request) Successful in 21s

- Use actionlint's official download script instead of hardcoded URL
  missing the version number in the asset filename
- Use pipx run for zizmor to avoid PATH and PEP 668 issues
- Add explicit permissions: contents: read to both workflows to
  satisfy zizmor's excessive-permissions audit

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-17 19:36:30 +01:00
parent 5240236759
commit 00a5a78a44
2 changed files with 8 additions and 4 deletions

View File

@@ -18,6 +18,9 @@ on:
- ".gitignore" - ".gitignore"
- ".github/workflows/deploy.yml" - ".github/workflows/deploy.yml"
permissions:
contents: read
jobs: jobs:
backend-lint: backend-lint:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@@ -45,14 +48,12 @@ jobs:
persist-credentials: false persist-credentials: false
- name: Install actionlint - name: Install actionlint
run: | run: |
curl -sL https://github.com/rhysd/actionlint/releases/latest/download/actionlint_linux_amd64.tar.gz | tar xz bash <(curl -sL https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
sudo mv actionlint /usr/local/bin/ sudo mv actionlint /usr/local/bin/
- name: Lint GitHub Actions - name: Lint GitHub Actions
run: actionlint run: actionlint
- name: Install zizmor
run: pip install zizmor
- name: Audit GitHub Actions security - name: Audit GitHub Actions security
run: zizmor .github/workflows/ run: pipx run zizmor .github/workflows/
frontend-lint: frontend-lint:
runs-on: ubuntu-latest runs-on: ubuntu-latest

View File

@@ -3,6 +3,9 @@ name: Deploy
on: on:
workflow_dispatch: workflow_dispatch:
permissions:
contents: read
jobs: jobs:
deploy: deploy:
runs-on: ubuntu-latest runs-on: ubuntu-latest