-
Notifications
You must be signed in to change notification settings - Fork 9.5k
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 state is not refreshed with new outputs value after apply #22607
Comments
This is hitting me as well. Ideally the remote backend would just support |
Same here: I added a new outputs.tf in one workspace and require these outputs to be read by the remote_state data source in another workspace in terraform cloud. I have no clue how to force a refresh of the outputs section in the state without actually randomly modifying the resource. |
For now.. i am just adding a random "foo=1" tag to a resource. Sucks, but works until this issue is addressed. |
I am having the same issue, any updates on how can this be fixed? |
Please do not post "+1" comments here, since it creates noise for others watching the issue and ultimately doesn't influence our prioritization because we can't actually report on these. Instead, react to the original issue comment with +1, which we can and do report on. |
Has anyone found a decent workaround to this until the terraform team get around to sorting this issue? I am aware that you can add random tags to resources, but I would rather not go through this method. Thanks |
Probably #15419 is related to this issue |
This is still an issue as of mid April. The other thread mentioned trying "terraform refresh" but it's not supported in TF cloud
Do I actually have to make some random unnecessary change to get it to take the newly added outputs? EDIT: I switched the settings in TF cloud from "remote" to "local" and then I was able to do a local "terraform apply" that, while finding no changes, DID update the "outputs" with my new output. |
There is a workaround that we used for this situation not so long ago - #23247 (comment) |
Plz 2 fix |
This support article mentions this issue and recommends Running locally with your workspace in local execution mode will work, and in fact you can just I'm thinking of working on a GitHub action that detects guaranteed output-only changes, where the diff only includes lines in |
Anyone figured this out yet or still an issue ? |
This is going to involve Terraform Cloud changes as well as possible changes to core. Please 👍 and subscribe to the issue rather than adding +1 or "any updates" comments to avoid notifying other subscribers. |
This should be addressed by #25047, which will be included in the forthcoming v0.13.0 release. |
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 Version
Terraform Configuration Files
Terraform (I am using Terraform Cloud, so this might be limited only to that) doesn't see updates in outputs.tf. I am using 2 workspaces, referencing output with data source in the second one and if I push new commit to VCS adding additional output value, Terraform Cloud workspace reports that there are no changes and stops after plan. After the state doesn't refresh with new output value.
Debug Output
Crash Output
Expected Behavior
State should refresh with new output value
Actual Behavior
Terraform (I am using Terraform Cloud, so this might be limited only to that) doesn't see updates in outputs.tf. I am using 2 workspaces, referencing output with data source in the second one and if I push new commit to VCS adding additional output value, Terraform Cloud workspace reports that there are no changes and stops after plan. After the state doesn't refresh with new output value.
Steps to Reproduce
data.terraform_remote_state.networking-dev.outputs.aws_region]
from another workspaceAdditional Context
Terraform Cloud environment.
I have to do any changes, even modify a tag to get new refreshed state.
References
The text was updated successfully, but these errors were encountered: