Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for CNAME settings #6

Open
akire0ne opened this issue Apr 16, 2021 · 2 comments
Open

Support for CNAME settings #6

akire0ne opened this issue Apr 16, 2021 · 2 comments

Comments

@akire0ne
Copy link

Hi,

I use buildthedocs inside a Github Action workflow
buildthedocs is overwriting my custom domain name in GitHub pages every time the docs is built.
There is no obvious way on how to achieve this and it would be nice to have some guidance to do that.

Thanks.

@akire0ne
Copy link
Author

I fixed it myself by appending this to my Sphynx conf.py file:

# Include CNAME file so GitHub Pages can set Custom Domain name
html_extra_path = ['CNAME']

CNAME must be put at the root directory of your docs and must contain your custom domain name you want to use in GitHub Pages

your.custom.domain.com

Would be nice if you share such info in your docs, I believe setting a custom domain name in GitHub pages is rather common use case/

@eine
Copy link
Collaborator

eine commented Apr 17, 2021

@achillemyette1 thanks for explaining your solution. In fact, BTD just builds the project with the makefile and configuration provided by the user, and then pushes the result to the repo/branch. Therefore, there should be no difference between using BTD or running sphinx and pushing manually. Did you do it manually first and the behaviour of BTD changed? Or did you try with BTD straightaway?

Would be nice if you share such info in your docs, I believe setting a custom domain name in GitHub pages is rather common use case/

It would interesting indeed. The sources of the docs are located in https://github.com/buildthedocs/btd/tree/master/doc. Up to submitting a PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants