Custom domain
1 minute read
Set the published URL
Put the domain in mizzen.yml, without a trailing slash:
url: https://docs.example.com
The engine uses url for canonical links, sitemap.xml, and social images. When the site also lives under a path, set base as well, such as /docs.
Point the domain at GitHub Pages
- In the repository, open Settings → Pages.
- Enter the domain in Custom domain and save.
- GitHub Pages writes a
CNAMEfile with the domain. Keep it at the root of the site's source (the foldersourcenames inmizzen.yml), so the engine copies it to the output. - At your DNS provider, point the domain at GitHub Pages: a
CNAMErecord for a subdomain such asdocs.example.com, or the documentedAandAAAArecords for the apex domain.
For the DNS values and the certificate check, see Managing a custom domain for your GitHub Pages site.