Table of Contents
Map domain name from GoDaddy to Amazon EC2 instance.
Introduction
In this tutorial, we are going to
- Create hosted zone
- Create recordset with domain and subdomains
- Add amazon namespace servers in the domain provider console
Get Elastic IP and Assign it to Amazon instance
- The first thing you need to do is get an Elastic IP, the instance IP can change during reboot etc but elastic IP are static IP’s so you should make sure you create one of them and assign it your running instance.More detailed info can be found here.
Create Hosted Zone and Record Sets
- Go to Amazon AWS -> services and select Route 53
- Click on Hosted Zones and create a hosted zone.
- Give the domain name you have bought, make sure that you don’t add www. to it.
- Any comment if you like
- Select type as Public Hosted Zone.
- You should see something like below on your screen, Name Space servers, usually there are 4 different entries.Make note of these as you need them in the last step.
- Now Create a recordset and add values as shown in image below
- Keep name field empty
- Type as A
- Alias as No
- Value – This should be the value of your elastic IP
- Routeing Policy: Simple
- Now we need to bring subdomain too, so www.yourdomain.com should also work
- In name field type www.
- Type as A
- Alias as Yes
- Alias Target from dropdown select your site name
- Routeing Policy: Simple
Add the Amazon NameSpaceServers in Control panel of Domain Provider
- Now go to GoDaddy domain console and under my domains, click on settings.
- Change the Namespace servers (you should see 2 servers name) from default to custom.
- Add all the 4 namespace servers you got in STEP 4, add them one by one. Save it and wait for a couple of minutes. Type your domain name in the browser and you should be redirected to your website.
My www does not resolve. I’ve tried this a ton of different ways.
What could be the issue?
Did you see the video on you tube ?
https://www.youtube.com/watch?time_continue=1&v=pjA9MyzUJNQ
Hi
I followed the steps as described, but it’s not working. Does it take time? How do I trouble shoot?
Regards
Matloob
No, it should be quick.
it didn’t work for me too, I sow in other video when you add the www you have to change the type to CNAME
Thanks Abhishek, this was helpful!
I will check back in future, to see more of your posts that may help me as a web developer.
Hi thanks for the tutorial.
It worked for me, but after the page loaded, the address in the address bar change into the one that ec2 has, how we keep use the domain instead of the ec2 ip.
thanks. I worked well for me.
Thanks for the tutorials….Its working
Thanks for your instructions. it worked for me.
Nice tutorial! very easy to understand.
Hi,
Do I need to remove Godaddy NameSpaceServers completely and keep only the AWS that I got?
This is what I did and it’s not working for me.
Thanks for the tutorials….It’s working..