Mobile app version of vmapp.org
Login or Join
Jennifer507

: Gh-pages not allowing multiple subdomains I am following the Github Pages tutorial. I thought I could have two domains: api.website.com and website.com, and the first is created via a folder called

@Jennifer507

Posted in: #Cname #Dns #Godaddy #MultiSubdomains #Subdomain

I am following the Github Pages tutorial. I thought I could have two domains: api.website.com and website.com, and the first is created via a folder called api in my main website folder where index.html is stored.

When I type in website.com as a subdomain, it says my site is ready to be published at website.com which is great. However I also want to have the domain api.website.com as an additional one, yet it overwrites the existing subdomain website.com. What am I doing wrong?



Steps I thought I would follow:

help.github.com/articles/adding-or-removing-a-custom-domain-for-your-github-pages-site/ https://help.github.com/articles/setting-up-a-custom-subdomain/ medium.com/@LovettLovett/github-pages-godaddy-f0318c2f25a#.ae41mob6t

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Jennifer507

1 Comments

Sorted by latest first Latest Oldest Best

 

@Odierno851

Create another repository for github pages for example api.github.io .Which is accessible from github.com/yourusername/api.github.io
Create separate branch with name gh-pages
Create a CNAME file which contain your subdomain name for example api.example.com then deploy it to your repository OR simply add your subdomain into custom domain filed. Make sure the branch is gh-pages
Configure CNAME records in your domain panel. For example host name is your subdomain api which point to your repository name api.github.io
Configure A records which point to github pages server.
Deploy your index.html and other file to your repository, make sure you push to gh-pages branch. For example git push origin gh-pages

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme