testdrivenio/django-ecs-terraform

Need at least 4 healthy instances in ASG, have 0.

organicnz opened this issue ยท 1 comments

Following your awsome article mate ๐Ÿ‘

Ready?!? View then execute the plan:
$ terraform plan
$ terraform apply

After Terraform apply I've got an error that Need at least 4 healthy instances in ASG, have 0.

ws_autoscaling_group.ecs-cluster: Still creating... [10m10s elapsed]

Error: "production_auto_scaling_group": Waiting up to 10m0s: Need at least 4 healthy instances in ASG, have 0. Most recent activity: {
  ActivityId: "9f05d49d-82b4-9711-3dc4-015de4ab3b25",
  AutoScalingGroupName: "production_auto_scaling_group",
  Cause: "At 2020-10-14T13:50:47Z an instance was started in response to a difference between desired and actual capacity, increasing the capacity from 0 to 4.",
  Description: "Launching a new EC2 instance.  Status Reason: The requested configuration is currently not supported. Please check the documentation for supported configurations. Launching EC2 instance failed.",
  Details: "{\"Subnet ID\":\"subnet-0f21a4e93054e04c2\",\"Availability Zone\":\"us-east-2a\"}",
  EndTime: 2020-10-14 13:50:48 +0000 UTC,
  Progress: 100,
  StartTime: 2020-10-14 13:50:48.613 +0000 UTC,
  StatusCode: "Failed",
  StatusMessage: "The requested configuration is currently not supported. Please check the documentation for supported configurations. Launching EC2 instance failed."
}

Fixed by avoiding usage of the created scripts and just simply cloning the repo.