EC2 Auto Scaling (45) (Incomplete)

  Uncategorized

 

Before you can configure an Auto Scaling group, you must first create a ‘Launch Configuration’.  This is the template that defines how each of the new instances will be provisioned.

Make sure you’ve already created a Load Balancer CLASSIC and Target Group

  • it did not see my Application LB!

 

  • EC2 > Auto Scaling > Launch Configurations > [Create Auto Scaling group] > [Create launch configuration]
  • AWS Linux AMI > t2.micro
  • Create Launch Configuration
    • Name: Autoscale
    • IAM role: S3Admin
    • Advanced Details
      • User data (This is your startup script)
      • #! /bin/bash
        yum update -y
        yum install httpd -y
        aws s3 cp s3://thomasandsofia /var/www/html --recursive
        service httpd start
        chkconfig httpd on
      • IP Address Type
        • Only assign a public IP
    • Add Storage
    • Select Security Group
  • Create Auto Scaling Group
    • Create an Auto Scaling group from an existing launch configuration
      • Select you Launch Config
    • Group name: HelloAuto
    • Group size: start with [2] instances
    • Network (Defaults to your VPC)
    • Subnet (Select all AZ available!)
    • Advanced Details
      • [x] Load Balancing
      • Classic Load Balancers > Select your LB
      • Target Groups > Select your Target Group
    • [Next]
    • (*) Keep this group at its initial size

LEAVE A COMMENT