Skip to content

docs: migrate to artifact-based GitHub Pages deployment#42

Merged
leonardosul merged 7 commits into
mainfrom
docs/migrate-to-pages-artifact-deploy
May 1, 2026
Merged

docs: migrate to artifact-based GitHub Pages deployment#42
leonardosul merged 7 commits into
mainfrom
docs/migrate-to-pages-artifact-deploy

Conversation

@leonardosul
Copy link
Copy Markdown
Contributor

Summary

  • Replace legacy mkdocs gh-deploy --force (pushes built HTML to gh-pages branch) with GitHub's recommended upload-pages-artifact + deploy-pages pattern (artifact-based deployment with environment tracking)
  • Add docs/requirements.txt with pinned version floors (mkdocs>=1.6, mkdocs-material>=9.5) — previously installed unpinned via bare pip install
  • Add workflow_dispatch trigger and self-watching (.github/workflows/docs.yml path) so docs can be manually re-deployed and workflow changes auto-trigger a rebuild
  • Add dark mode toggle, instant navigation, section tracking, expandable nav, code copy/annotate, admonitions, details, and search plugin
  • Move docs/CNAME to docs/overrides/CNAME so the custom domain file is included in mkdocs build output (required for artifact-based deploy)
  • Add site/ to .gitignore
  • Add .github/CODEOWNERS assigning @leonardosul and @monk-ee as code owners for all files

Migration note

After merging, the repo's GitHub Pages settings need to be updated:

  • Source → "GitHub Actions" (instead of "Deploy from a branch")
  • The gh-pages branch can be deleted once the first artifact-based deploy succeeds

Test plan

  • mkdocs build succeeds locally
  • CNAME file (nat-zero.machine.dev) present in site/ output
  • All pre-commit hooks pass
  • After merge: verify GitHub Pages deploys via the Actions artifact pipeline
  • After merge: verify nat-zero.machine.dev serves correctly

🤖 Generated with Claude Code

leonardosul and others added 7 commits May 1, 2026 10:32
Replace legacy `mkdocs gh-deploy --force` (branch push) with the
GitHub-recommended upload-pages-artifact + deploy-pages pattern. Also
adds pinned docs dependencies, workflow_dispatch trigger, dark mode,
and richer markdown extensions.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace pip + requirements.txt with uv + pyproject.toml dependency
group and lockfile. Move CNAME back to docs/ root since mkdocs copies
it to site/ automatically without needing a custom_dir overlay.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Reflect artifact-based Pages deploy, uv dependency management,
CODEOWNERS, tag creation rule, SHA pinning enforcement, and
disabled workflow PR approvals.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The workflow-level permissions remain as the ceiling (union of all
jobs), but each job now narrows to only what it needs: integration
gets id-token+contents:read, nat-images gets id-token+contents:write+
pull-requests:write, and clear-trigger-label gets only issues:write.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The repo-level SHA pinning enforcement rejects transitive tag
references inside composite actions (pre-commit/action uses
actions/cache@v4 internally), breaking precommit CI. Pinning
remains enforced by convention in our own workflow files.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@leonardosul leonardosul added the integration-test Triggers integration tests label May 1, 2026
@leonardosul leonardosul merged commit 15f0a3e into main May 1, 2026
8 checks passed
@leonardosul leonardosul deleted the docs/migrate-to-pages-artifact-deploy branch May 1, 2026 03:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration-test Triggers integration tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant