jekyllgithub-pagescnamebase-urlcustom-url

Jekyll website hosted on gh-pages via github. Need to use a custom URL


I am wanting to use a custom URL for this github website, but I ran into issues when I tried. The repo is below if you want to view my files. I had to do a 'git reset --hard "commit" ' to get it working again!

I dont know if I need to change my base URL too because none of the css worked, and no href links to other pages on the server worked either. Then I was getting build errors on github with no details as to why.

Steps I took:

1) I have a domain with godaddy

2) Then I went to github and changed the Custom url to the domain i have on github.

3) Then github created a cname file by its self with my url in it

4) I went to godaddy and pointed to the servers provided by github.

5) It display my html files, but no href links work, and CSS is not working. I think it has something to do with the base url or something...

https://github.com/jose-reyes-9/school-amp-1


Solution

  • In _config.yml change :

    baseurl: ""
    url: "http://yourcustome-domain-url.com"
    

    And add a CNAME because github doesn't create it for you.