-
Notifications
You must be signed in to change notification settings - Fork 9.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aws vpc destroy fails with unmap public addresses before detaching gateway #1303
Comments
@franklinwise if you look at #1189 you will see some discussion about this. I was having a similar issue, and what I did was add a depends_on = ["aws_internet_gateway.gw"] to the instance that was getting an elastic IP and the problem went away. (of course .gw will be whatever you called it). |
@mitchellh perhaps an implied dependency of the internet gateway for anything getting a public IP/Elastic IP might be in order. For me, the only time this happens is when I use an Elastic IP. All other instances that get a public IP have no issues. Also, if I run a destroy a second time, it finished the destroy properly. |
Hey @kendawg2 , thanks for reporting this. Do you have an example config I can use? Please omit any secrets. |
Reproduced with the config example here in 1189. I'm seeing if I can add error handling to Internet Gateway as a bandaid, but the current solution is the explicit |
I merged a fix for this in #1325 |
Awesome! Thanks @mitchellh & @catsby |
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. |
upon attempting to destroy an aws vpc setup I get the following error:
Network vpc-d440fdb1 has some mapped public address(es). Please unmap those public address(es) before detaching the gateway.
Seems like destroying should just work. Perhaps unmapping public addresses needs to happen at the beginning of destroy?
Terraform v0.4.0-dev (28ecdac)
The text was updated successfully, but these errors were encountered: