You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
running it the first time goes fine. Second time though, it seems to infer changes without the config have changed, which makes it want to recreate the auto scaling group:
$ make tf-apply
mkdir -p build
cd terraform; terraform apply
aws_security_group.nat: Refreshing state... (ID: sg-f3969396)
aws_security_group.db: Refreshing state... (ID: sg-59f6ae3c)
aws_security_group.ssh: Refreshing state... (ID: sg-71c8cc14)
aws_security_group.external_web: Refreshing state... (ID: sg-60d7f005)
aws_security_group.jump: Refreshing state... (ID: sg-51f6ae34)
aws_vpc.dryleaf: Refreshing state... (ID: vpc-129a2c77)
aws_launch_configuration.cyclops_lc: Refreshing state... (ID: dryleaf-cyclops-lc)
aws_internet_gateway.gw: Refreshing state... (ID: igw-7d1fd718)
aws_subnet.db-1d: Refreshing state... (ID: subnet-d1f027a6)
aws_subnet.db-1a: Refreshing state... (ID: subnet-1685744f)
aws_subnet.private-1d: Refreshing state... (ID: subnet-16329661)
aws_subnet.private-1a: Refreshing state... (ID: subnet-1ac50343)
aws_subnet.app-1d: Refreshing state... (ID: subnet-17329660)
aws_subnet.app-1a: Refreshing state... (ID: subnet-1fc50346)
aws_subnet.front-1d: Refreshing state... (ID: subnet-d4f027a3)
aws_subnet.front-1a: Refreshing state... (ID: subnet-09857450)
aws_route_table.public: Refreshing state... (ID: rtb-c55feba0)
aws_instance.wolverine: Refreshing state... (ID: i-e68cc50b)
aws_instance.nat_box: Refreshing state... (ID: i-f13f701c)
aws_route_table_association.app-1a: Refreshing state... (ID: rtbassoc-62009007)
aws_route_table_association.app-1d: Refreshing state... (ID: rtbassoc-61009004)
aws_route_table_association.front-1a: Refreshing state... (ID: rtbassoc-60009005)
aws_route_table_association.front-1d: Refreshing state... (ID: rtbassoc-63009006)
aws_elb.web_elb: Refreshing state... (ID: dryleaf-web)
aws_autoscaling_group.cyclops_asg: Refreshing state... (ID: dryleaf-cyclops-asg)
aws_autoscaling_group.cyclops_asg: Destroying...
aws_security_group.db: Modifying...
ingress.0.security_groups.#: "0" => "1"
ingress.0.security_groups.0: "" => "sg-59f6ae3c"
ingress.0.self: "1" => ""
aws_security_group.external_web: Modifying...
ingress.0.cidr_blocks.#: "1" => "0"
ingress.0.cidr_blocks.0: "0.0.0.0/0" => ""
ingress.0.from_port: "80" => "443"
ingress.0.self: "0" => ""
ingress.0.to_port: "80" => "443"
ingress.1.cidr_blocks.#: "1" => "0"
ingress.1.cidr_blocks.0: "0.0.0.0/0" => ""
ingress.1.from_port: "443" => "80"
ingress.1.self: "0" => ""
ingress.1.to_port: "443" => "80"
aws_autoscaling_group.cyclops_asg: Error: ResourceInUse: You cannot delete an AutoScalingGroup while there are instances or pending Spot instance request(s) still in the group.
aws_security_group.db: Modifications complete
aws_security_group.external_web: Modifications complete
aws_launch_configuration.cyclops_lc: Modifying...
image_id: "ami-24ac174c" => "ami-24ac174c"
instance_type: "t2.medium" => "t2.medium"
key_name: "qwaya-default" => "qwaya-default"
name: "dryleaf-cyclops-lc" => "dryleaf-cyclops-lc"
security_groups.#: "1" => "2"
security_groups.0: "sg-71c8cc14" => "sg-71c8cc14"
security_groups.1: "" => "sg-60d7f005"
aws_elb.web_elb: Modifying...
health_check.0.healthy_threshold: "10" => "3"
health_check.0.target: "TCP:80" => "HTTP:80/_monitor"
health_check.0.timeout: "5" => "3"
health_check.0.unhealthy_threshold: "2" => "3"
listener.0.instance_protocol: "HTTP" => "http"
listener.0.lb_protocol: "HTTP" => "http"
aws_launch_configuration.cyclops_lc: Error: ResourceInUse: Cannot delete launch configuration dryleaf-cyclops-lc because it is attached to AutoScalingGroup dryleaf-cyclops-asg
aws_elb.web_elb: Modifications complete
Error applying plan:
1 error(s) occurred:
* ResourceInUse: You cannot delete an AutoScalingGroup while there are instances or pending Spot instance request(s) still in the group.
Terraform does not automatically rollback in the face of errors.
Instead, your Terraform state file has been partially updated with
any resources that successfully completed. Please address the error
above and apply again to incrementally change your infrastructure.
Makefile:15: recipe for target 'build/terraform_marker_file' failed
make: *** [build/terraform_marker_file] Error 1
The text was updated successfully, but these errors were encountered:
I have a aws_autoscaling_group and a aws_launch_configuration like so:
running it the first time goes fine. Second time though, it seems to infer changes without the config have changed, which makes it want to recreate the auto scaling group:
The text was updated successfully, but these errors were encountered: