I'm interested in migrating from a manually managed AWS EC2 cloud with multiple webapps to AWS ELB with auto scalling. However, I'm not sure whether a single ELB will be enough to handle my architecture.
My current architecture is following:
- my infrastructure consists of about 50 ec2 micro instances, which server 50 different webapps, one instance per app and those are usually enough,
- the traffic is routed through an ec2 instance with nginx installed, which directs connections according to anames (let's say that my domain is abc.com and server app1 (22.214.171.124) is responsible for handling app1.abc.com and server app2 is responsible for app2.abc.com),
- the traffic sometimes spikes, but not periodically or predictably,
- if the utilization is high enough I manually create another ec2 instance of a server with appx and supply its info into nginx,
- after the high traffic period I stop/terminate unnecessary instances.
The main problem in this architecture is that I need to manually react to traffic changes. Because of that, I was thinking to take advantage of AWS auto scalling, since I'm using AWS anyway, but after scale out is applied I would still need to manually modify nginx and again after scale in. The solution is to use ELB, which can react to auto scalling, however I'm not sure how it would handle multiple auto scalling groups (one per aname) and multiple anames linked to concrete servers.
If a single ELB with auto scalling is not capable of that and having 50 different ELB for mostly single machines is out of the question, are there any alternatives to achieve this level of automation in such architecture?