I am working to migrate our servers to Amazon Cloud, for reasons of autoscaling, cost, services, etc., obviously.
Until now, I am experimenting a lot and trying to dive into the fully functional documentation, but without previous experience I have many questions.
The provided infrastructure is as follows:
+-----+ | ELB | +--+--+ | +--------------------|--------------------+ | Auto-Scaling Group | |--------------------|--------------------| | | | | +---------+ | +---------+ | | | varnish |<------+------>| varnish | | | +----+----+ +---------+ | | | | | +-----------------------------------------+ | | | | | +------------+ | +---->|Internal ELB|<-----+ +------+-----+ | +-----------------------------------------+ | Auto-Scaling Group | |-----------------------------------------| | +---------+ | +---------+ | | | Apache |<------+------>| Apache | | | +----+----+ +----+----+ | | | | | +-----------------------------------------+ | +-----+ | +-------->| RDS |<--------+ +-----+
In words, I will have Elastic LoadBalancer, which will send traffic to Varnish instances, which, in turn, will send traffic to the internal Elastic LoadBalancer, which will send traffic to Apache interfaces.
Currently, I have discovered AWS tools, such as CloudFormation , which seems to be able to load the instance specified by the template, seems to be great, but it seems to only load.
Having little experience with Puppet (and considering AWS's recommendation on this), I fell in love with the Puppet thing, which is a great tool.
My idea, which may be unviable or realistic, is to create a “puppet Node stack” using CloudFormation templates that will customize the instance as needed and connect the doll master layout to it.
Once my stack is ready, I wonder how to set up / create an Auto-Scaling group for Varnish and Apache instances.
It seems that CFN has the resources to configure groups and auto-scaling policies, so I think I could create two different templates for each.
But will the AS function work through the CFN service and then do all the init actions (and do user-data )?
I also read here and there that Puppet can use EC2 tags, maybe a common stack template with corresponding tags (e.g. roles) could do the trick?
Is this architecture realistic and sustainable? Do you have any feedback?
Thanks for your advice.