Multiple domains on Amazon AWS EC2
I am a bit confused on how I can use Amazon AWS to host multiple websites. I under stand how to host a website on there however I am only allowed up to 5 elastic ip addresses. So how would I host more than 5 domains if I cannot assign an ip address to each domain? I could use the Amazon Public DNS address provided which is something like (xxx.xxx.xxx.xxx.compute-1.amazonaws.com) however I cannot use this as a A record when it comes to changing the domain's DNS.
Help?
Solution 1:
You only need one elastic IP address. The rest can be achieved using name based virtual hosting.
- Create an A record that points to your elastic IP address for your main host.
- Create a CNAME record for each of the additional domains that you want that points to you main domain name A record.
- Create a virtual host for each domain.
Solution 2:
For web sites, the only time you absolutely need multiple IP's is when you're doing SSL (HTTPS) for multiple sites.