Hi there,
Thank you for opening an issue. Please note that we try to keep the Terraform issue tracker reserved for bug reports and feature requests. For general usage questions, please see: https://www.terraform.io/community.html.
Terraform v0.7.3
Please list the resources as a list, for example:
Terraform should always update aws_instance security group attachments before trying to destroy an existing security group.
Terraform tried to destroy security groups that were attached to an instance. The apply ran for 5 minutes before timing out. Then, Terraform attempted to continue applying by creating new security groups, which failed because the old security groups still existed.
Please list the steps required to reproduce the issue, for example:
I can confirm this behaviour. My plan says it's going to destroy and create the security group (because I wanted to rename it) and then alter the EC2 instance to use the new security group. It hangs at destroying the security group though.
It's possible that some of the sgs I was experiencing this with were also referencing other sgs that were also supposed to be destroyed.
That goes for me as well if I recall correctly. I had a security group for an SSH bastion server and a security group for private hosts that only allow incoming SSH from the SSH bastion security group.
:+1: I get the same behaviour
I'm going to lock this issue because it has been closed for _30 days_ โณ. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Most helpful comment
I can confirm this behaviour. My plan says it's going to destroy and create the security group (because I wanted to rename it) and then alter the EC2 instance to use the new security group. It hangs at destroying the security group though.