Add static/CNAME (identus.io) so Docusaurus ships it in the build
output. release-gh-pages.yml publishes ./build to the gh-pages branch
via peaceiris/actions-gh-pages, so the build now carries CNAME and the
custom-domain configuration survives every deploy.
Without this, the hand-added CNAME on gh-pages is wiped on each deploy
(./build had no CNAME), which disables the identus.io custom domain.
The site then falls back to the project path
hyperledger-identus.github.io/docs/ while still built with baseUrl '/',
so /assets/* 404s and Docusaurus shows the "site did not load properly"
banner. This is the root cause behind the repeated manual
"Create CNAME" commits on gh-pages.
Signed-off-by: Pat Losoponkul <patextreme@hotmail.com>
Problem
The docs site (https://identus.io/) has been repeatedly breaking: the page goes unstyled and shows Docusaurus' red "Your Docusaurus site did not load properly" banner, with all
/assets/*bundles returning 404.Root cause
Since #269 the site is built for the
identus.ioapex custom domain (url: 'https://identus.io/',baseUrl: '/'). That requires aCNAMEfile on the publishedgh-pagesbranch.release-gh-pages.ymldeploys./buildtogh-pageswithpeaceiris/actions-gh-pages@v3(nokeep_files), which replaces the branch on every deploy. Because there was noCNAMEin the Docusaurus build, each deploy deleted the hand-addedgh-pages/CNAME, silently disabling the custom domain. GitHub then falls back to serving at the project pathhyperledger-identus.github.io/docs/, but the build still references assets at root (baseUrl: '/') →/assets/*404 → broken.This produced ~9 manual
Create CNAME/Update CNAME/Delete CNAMEcommits ongh-pagesover the last month (by @ryjones, @elribonazo, @patextreme) — each fix only lasting until the next push tomain.Fix
Add
static/CNAMEcontainingidentus.io. Docusaurus copiesstatic/*into./build, so theCNAMEnow ships with every deploy andpeaceirispreserves it. The custom domain stays enabled permanently; no more manual re-adds.Verification
static/CNAME→build/CNAMEconfirmed by Docusaurus static-asset pipeline (same mechanism already used forstatic/.nojekyll)./documentation/learn/): no banner, fully styled, hydrated.hyperledger-identus.github.io/docs/301-redirects toidentus.io.Alternatives considered
keep_files: trueon the peaceiris action — works but can leave stale files;static/CNAMEis the documented Docusaurus approach and is self-contained in the build.baseUrl: '/docs/'— would undo the intentionalidentus.iobranding move in chore: update URL for docs #269.