Search code examples
amazon-web-servicesdnssubdomain

Can we use a sub domain for our aws ec2 instance?


I have bought a domain from nexcess.net (example.com) on which my website is hosted, now I have to create a secondary domain (one.etc.example.com) from the nexcess site and point it to my ec2 instance. Is it possible using nexcess? Can anyone guide me how?


Solution

  • The steps would be:

    • Create an Elastic IP address and associate it with the EC2 instance (this gives it a static IP address)
    • Create an A record in your domain to point the desired domain name

    You can create the A record where ever your domain is managed, whether it is using Amazon Route 53 or your own DNS provider.