mirror of
https://github.com/storytold/photocraft.git
synced 2026-12-02 06:20:48 +01:00
Mutable action tags are a supply-chain risk: a moved tag runs different code without a diff. Every workflow action is now pinned through .github/workflows/actions.lock, and CI verifies the lockfile so an out-of-sync or tampered one fails instead of running.
46 lines
963 B
YAML
46 lines
963 B
YAML
name: Documentation
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
paths:
|
|
- "book/**"
|
|
- "docs/**"
|
|
- "README.md"
|
|
- "SECURITY.md"
|
|
- ".github/workflows/docs.yml"
|
|
pull_request:
|
|
paths:
|
|
- "book/**"
|
|
- "docs/**"
|
|
- "README.md"
|
|
- "SECURITY.md"
|
|
- ".github/workflows/docs.yml"
|
|
workflow_dispatch:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
concurrency:
|
|
group: docs-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
build:
|
|
timeout-minutes: 15
|
|
name: mdBook build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Harden runner
|
|
uses: step-security/[email protected]
|
|
with:
|
|
egress-policy: audit
|
|
- uses: actions/[email protected]
|
|
- uses: step-security/[email protected]
|
|
with:
|
|
toolchain: stable
|
|
- name: Install mdBook
|
|
run: cargo install mdbook --version 0.4.52 --locked
|
|
- name: Build documentation
|
|
run: mdbook build book
|