0

I have a CentOS instance. Is it possible for multiple domains / subdomains to share that single instance and on my Apache server i will have separate folders for each domain. How do I start doing this and how would I map my subdomains to the instance.

1

You should read up on Name Based Virtual Hosting. Get an elastic IP address for your instance. Create a DNS entry that points each domain name to the elastic IP address. Create a virtual host for each domain.

1

Sure, EC2 is no different from any other server in that regard. You setup separate virtual hosts for each domain, and then modify the DNS entries for the domains to point to the public IP address of the EC2 instance. You'll probably want to get an Elastic IP so that your public IP address doesn't change every time your EC2 instance reboots, and an EBS volume to put all the content onto so you don't have to re-roll your base image every time your vhost's content changes.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.