Skip to content
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

Terraform trying to delete Internet gateway before deleting the load balancer and fails. #373

Open
Karthikraja9 opened this issue Mar 27, 2024 · 0 comments

Comments

@Karthikraja9
Copy link

Karthikraja9 commented Mar 27, 2024

#54
This issue ^^^ reoccurs in Terraform 1.7.5.

Error: deleting EC2 Internet Gateway (igw-xxxxxxxxxxxxxxxxx): detaching EC2 Internet Gateway (igw-xxxxxxxxxxxxxxxxx) from VPC (vpc-xxxxxxxxxxxxxxxxx): DependencyViolation: Network vpc-xxxxxxxxxxxxxxxx has some mapped public address(es). Please unmap those public address(es) before detaching the gateway. status code: 400

The Public IP its referring to is attached to the Load balancer, still Terraform is trying to delete the Internet Gateway first and then the LB which is resulting in the above error.
Note: LB termination protection is off.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant