Open sparr opened 3 months ago
Voting for Prioritization
Volunteering to Work on This Issue
I deleted the listener in question and tried to apply
again. Again the subnet and sg and igw failed to delete. The sg still has the lb eni attached. I'm deleting the lb manually and trying again.
deleting the lb manually resolved the problem. I will attempt to come back later with a minimal reproduction test case.
Hey @sparr 👋 Thank you for taking the time to raise this! Were you able to put together a minimal test case so that we could look at this a bit further?
I have not yet had time. This is still on my todo list.
Terraform Core Version
1.5.7
AWS Provider Version
5.61.0
Affected Resource(s)
Expected Behavior
Attempting to replace an aws_subnet should succeed, temporarily removing the aws_lb_listener rule (or the whole aws_lb_listener) referencing the aws_lb_target_group that is necessarily being replaced because the aws_lb is being replaced
Actual Behavior
Replacement failed because the old subnet could not be deleted because it has an attached network interface, which is attached to the load balancer, which has a listener with a rule pointed at a target group, and the target group fails to delete because the rule still exists.
Relevant Error/Panic Output Snippet
Terraform Configuration Files
I will try to produce a minimal test case when I can. I am still working on bypassing this problem.
Steps to Reproduce
I will try to produce a minimal test case when I can. I am still working on bypassing this problem.
Debug Output
No response
Panic Output
No response
Important Factoids
No response
References
No response
Would you like to implement a fix?
Yes