AWS Autoscaling#
Creating an environment manually#
-
SecurityGroup
alb-sg- allow
tcp/80from0.0.0.0/0 - allow
tcp/443from0.0.0.0/0
- allow
-
SecurityGroup
alb-2-app-sg- allow
tcp/80from self - allow
tcp/443from self
- allow
-
TargetGroup
-
LoadBalancer (pointing to TargetGroup)
-
LaunchTemplate
-
Autoscalinggroup
- Add to sg
alb-2-app-sg - register ASG with TG
- use Default version from
- Add to sg
Using a custom image#
- create separate instance
- connect via SSH
- install the
nginxweb server - in EC2 create image
- modify to use new image
- start instance refresh
Add a database#
-
SG
app-2-db -
create instance
-
copy connection information around
- follow aws-autoscaling.md#Using a custom image to recreate image
and renew instances
- follow aws-autoscaling.md#Using a custom image to recreate image
[aws-autoscaling.md#Using a custom image]: <#Using a custom image> "AWS Autoscaling"