feat: deploy to git-pages instead of SCP (with preview deploys) #17
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/git-pages-deploy"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #3
What changes
Workflow (
build.yml): replaces SCP/SSH deploy with git-pages deploymentpublic/, PUTs to git-pages via Forge-Authorizationradu.pages.martin.md/blog, served atblog.martin.mdvia custom domainradu.preview.pages.martin.md/blog@{N}with--baseURLset for correct asset pathsForge-Authorization: Bearer— git-pages verifies the CI token against the Forgejo APIgithub.head_ref)Server config: lives in homelab/dc-git-pages
Preview deployments
PRs deploy to
https://radu.preview.pages.martin.md/blog@{N}/on every push.Prerequisites
Merged and deployed on kronos:
Cleanup after migration
Replace the SSH/SCP deployment with git-pages: - Push built site to pages branch (production) or pages/preview/pr-{N} (preview) - Notify git-pages via PUT request - Supports pull_request preview deployments Removes all SSH secrets and the nginx dependency.Push to pages branch (production) or pages/preview/pr-{N} (preview). A Forgejo webhook to http://127.0.0.1:3000/ triggers git-pages to clone and serve the pages branch on every push. No SSH secrets needed. No runner-to-git-pages notification needed.