Been a while! I thought I’d resurrect the blog and treat myself to my own domain. Linking them turned out to be quite easy - read below.
Custom Domain on AWS
I chose to register my new domain using AWS and Route53, it was really easy:
- Follow the steps outlined in the documentation here. I initially wanted an
.io
domain but damn they’re expensive (apparently only because they are trendy). I settled forbartparka.com
. - Once you have your domain and it has been successfully registered, you will need to create two records if you want both
example.com
andwww.example.com
to correctly resolve/redirect to your blog pages. - The steps are outlined here, but in essence you need to create two records (see screenshot below):
- A record - pointing at GitHub Pages ips in above link.
- CNAME record - pointing at the
<user>.github.io
address of your GitHub pages url.
- Once done, navigate to your repo -> Settings -> Code and automation -> Pages and change the Custom domain to match your newly created domain (see screenshot below).
- You may have to wait a few minutes to tick Enforce HTTPS.
That’s it!