Cloudflare + AWS route 53 combined to handle records
okay, after tinkering around. I finally got it working! thanks for everyone for their help. If anyone else is in the same situation as me. Here is what you have to do.
I bought the domain from Godaddy, so under the nameserver, I used the name server from Cloudflare(there should only be 2 from cloudflare)
Cloudflare manages all of my services, but I only wanted one subdomain(firmware.mywebsite.com) to be directed to amazon route53, and leave the others where they are.
- Create a hosted zone in your amazon route 53, of your domain, should be *.yourwebsite.come
in this hosted zone, there should be 2 entries by default, one is the SOA record and the other one is sub-entries of Name servers from amazon.
- Add the subdomain you want to be controlled by route 53 on cloudflare under the NS field.
so for example, you wanted firmware.mywebsite.com to be controlled via route 53,
add that in as the first field into the cloudflare NS registry, the second field is the name server from amazon, you need to add ALL 4 of them into cloud flare.
Add the subdomain entry on the route 53 side, so it would be firmware.mywebsite.com, then select the type of record(A, cname, etc),and where you want it redirect to.
set the TTL to short time(2min) to see the propagation.
Everything should be setup!
If you go this route, for every subdomain you wanted to be controlled by route53, there needs to be 4x entry for that subdomain on cloudflare.
Hope this be useful for someone else in situation!
Related videos on Youtube
John
Updated on September 18, 2022Comments
-
John over 1 year
I bought my domain from Godaddy,
I use cloudflare for most of my services, so i added the nameserver to my godaddy domain configuration.
So lets say I have
api.mydomain.com firmware.mydomain.com forum.mydomain.com
as CNAME records pointed to my AWS Load balancer.
However, I want to use firmware.mydomain.com to be on route 53, specifically for its geolocation routing and latency routing, But I want to have my remaining 2 services to be on cloudflare
Now When I added amazon route53 name servers to my godaddy account. A bunch of my services that was registered on cloudflare started to go down and become unreachable.
I removed those nameserver entries from godaddy, and everything works again.
Now my questions is.
Why did this happen?
If I add nameserver from route53, does it have to be a duplicate of all of the services on cloudflare for it to work?
Thanks
-
ceejayoz about 7 yearsDelegate just the
firmware.mydomain.com
subdomain to Route53 via NS records in CloudFlare. -
John about 7 yearsthere is 4 entries in the route53 hosted zone, would I delegate firmware to those nameserver?
-
ceejayoz about 7 yearsYes, you would.
-
Tim about 7 years@TylerLiu If you've found a solution please post it in the answer box below, so others can learn from your experience
-
John about 7 yearsthanks @ceejayoz, I got a solution. posted the solution below! thanks!
-
-
Ivan Milisavljevic over 6 yearsOne thing thought, you cant create *.domain zones, it has to be root domain