Skip to content

fix(ci): write CNAME into docs/ so Pages keeps the custom domain#71

Merged
samuelduchesne merged 1 commit into
mainfrom
fix/gh-pages-cname-in-docs
May 20, 2026
Merged

fix(ci): write CNAME into docs/ so Pages keeps the custom domain#71
samuelduchesne merged 1 commit into
mainfrom
fix/gh-pages-cname-in-docs

Conversation

@samuelduchesne
Copy link
Copy Markdown
Collaborator

Summary

  • GitHub Pages on this repo publishes from gh-pages:/docs (confirmed by the PR preview URL mcp.idfkit.com/pr-preview/pr-N/ mapping to gh-pages-deploy/docs/pr-preview/pr-N/).
  • Both deploy workflows only placed CNAME at the branch root. The build step then overwrote docs/ with the freshly built site, which contains no CNAME — so Pages saw a published folder without CNAME and cleared the custom domain on every run.
  • This adds mcp.idfkit.com to docs/CNAME in both deploy-docs.yml (main deploy) and deploy-pr-docs.yml (PR previews), alongside the existing root CNAME.

Why not switch to peaceiris/actions-gh-pages?

The sibling repo idfkit/idfkit doesn't have this problem because it uses peaceiris/actions-gh-pages@v4 with cname: py.idfkit.com, which writes CNAME into the published folder automatically. Keeping the custom script here but fixing the CNAME placement is the smallest change.

Follow-up

After this merges, re-set the custom domain to mcp.idfkit.com once in Settings → Pages. Subsequent deploys will preserve it.

Test plan

  • Merge and confirm mcp.idfkit.com survives the next deploy-docs run.
  • Open a PR after merge and confirm the preview deploy doesn't reset the domain either.

🤖 Generated with Claude Code

GitHub Pages publishes from gh-pages:/docs on this repo, but the deploy
workflows only placed CNAME at the branch root. Each deploy overwrote
docs/ with the freshly built site (which contains no CNAME), so Pages
saw a published folder without CNAME and reset the custom domain in
settings on every run.

Write mcp.idfkit.com into docs/CNAME in both the main deploy and PR
preview workflows, in addition to the root CNAME.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
github-actions Bot added a commit that referenced this pull request May 20, 2026
@github-actions
Copy link
Copy Markdown
Contributor

Docs preview for this PR is available at:
https://mcp.idfkit.com/pr-preview/pr-71/

@samuelduchesne samuelduchesne merged commit 9f8906d into main May 20, 2026
8 checks passed
@samuelduchesne samuelduchesne deleted the fix/gh-pages-cname-in-docs branch May 20, 2026 17:07
github-actions Bot added a commit that referenced this pull request May 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant