-
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
plan is in a loop changing my "main" route table #2879
Comments
@catsby we are seeing this as well -- basically if you associate a route table with an ENI that is associated with an instance, AWS also returns the instance ID on subsequently queries for the route table which causes terraform to think that there is a diff. We took a crack at fixing this today, but the nuances around I think the correct behavior is to have the instance id be persisted to the state file, but not be considered a diff. Here is a diff with a failing test case:
|
I am running into this issue with eni's -> ~ aws_eip.nat_elastic_ip ~ aws_route_table.app-subnet ~ aws_route_table.databases-subnet |
@gtmtech unfortunately, no, in our case we just permit the route table update to go through. |
Just ran into this issue myself. Same scenario with using the eni parameter.
|
Still getting this behaviour in v0.6.6 |
+1 to find a solution. We are facing the same issue. |
+1 I believe I'm facing the same issue.
Part of the output I get every time I run plan or apply. This is for the default route table as well as two secondary route tables.
|
Related issue #4097 which is the other side of the coin. If you create a route table entry with an instance id, then do a subsequent plan, Terraform wants to erase the network interface ID that AWS assigns. When Terraform creates a route, then refreshes the state, it needs to expect that AWS is filling in some of the "missing pieces" and simply add those to the state without wanting to change the route resource back to "what it thought it should be". |
Following up on this for @jszwedko (I work with him). We were able to get a workaround by declaring the route entries as separate resources and not inline in the route_table. The diff will show if you declare the routes inline in the route_table but not when declared as separate resources. I verified this behavior on version 0.9.2 and version 0.8.8 |
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. |
terraform plan...
The text was updated successfully, but these errors were encountered: