0

I have a portal on amazon ec2. Which Many domains and also cname's point to this server elastic IP. Like aaa.com, bbb.com, ccc.com, *.abc.com.

now I want to take to behind load balancer. The main issue for me is when I take a request the content of portal is generated based on url entered. So programmatically www.aaa.com and aaa.com is also different for app.

How do I resolve this issue?

gandil
  • 104
  • 2
  • 10
  • Initially an exact duplicate of [Load Balancing in Amazon EC2 with multiple CNAME](http://serverfault.com/questions/289226/load-balancing-in-amazon-ec2-with-multiple-cname) - I have previously edited the other question to tidy it up. – crb Jul 12 '11 at 18:50

1 Answers1

1

You can set your server software to use a virtual host and direct the requests to different document roots. Or, you can use whichever programming language you like and check the request's hostname parameter, adapting the page as necessary from that.

Kyle
  • 1,589
  • 9
  • 14