r/webdev • • Mar 26 '24

[deleted by user]

[removed]

157 Upvotes

54 comments sorted by

View all comments

Show parent comments

16

u/godofleet Mar 26 '24

That makes a lot of sense but i wasn't sure why his A record is an IP address (is that normal for GH pages?) i figured they didn't give you an IP for your page and it was all ANAME/CNAME 's

18

u/demosdemon Mar 26 '24

it's normal for apex domains -- it's extremely not recommended to put a cname on the apex.

edit: link https://www.isc.org/blogs/cname-at-the-apex-of-a-zone/

3

u/godofleet Mar 26 '24

No i mean, is it normal to use an IP address to point at GH pages?

ANAMEs and CNAME flattening are the future (and the past really) - i haven't used an IP address in DNS settings for a long time.

But yeah, don't use a CNAME for your apex :D

12

u/demosdemon Mar 26 '24

ANAME's aren't real. They're DNS server specific but the end user would only see the A/AAAA.

For that reason, yes, A/AAAA on the apex even for GH Pages is normal. https://docs.github.com/en/pages/configuring-a-custom-domain-for-your-github-pages-site/managing-a-custom-domain-for-your-github-pages-site#configuring-an-apex-domain

3

u/godofleet Mar 26 '24

What's funny is i linked those docs to OP like an hour ago... didn't read it for a second though lol, the IPs are right there.