0. Create a Github Pages Project

There are two types of Github Pages projects:

  1. User Page: points to http://my-username.github.com/
  2. Project Page: points to http://my-username.github.com/my-project

To create a User Page pointing to http://my-username.github.com/, do the following:

  1. Create a Github Project on Github named "my-username.github.com"
  2. Create the base project:

    1
              2
              3
              4
    mkdir my-username ; cd my-username
              touch CNAME
              touch index.html
              git init
              
  3. Add the text mydomain.com to the CNAME file, that's it.

  4. Add something to the index.html file so you know it's working:

    1
              2
              3
              4
              5
              6
              7
              8
              9
    <!DOCTYPE html>
              <html>
                <head>
                  <title>Viatropos</title>
                </head>
                <body>
                  <h1>It's working</h1>
                </body>
              </html>
              
  5. Push to github:

    git add . ; git commit -a -m 'first-commit' ; git push origin master
              

1. Signup for Zerigo

Zerigo is a free Domain Management System SaaS, among other things. They make it easy to configure your domains. Way easier than anything I've ever seen.

2. Create an A record and a CNAME record for your domain name

They should look like this:

Zerigo A and CNAME records for Github Pages

You'll probably have to wait up to 48 hours to see your new subdomains live.