You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When there are no changes, terraform plan should show no changes
Actual Behavior
On every terraform plan, the tags entries are marked for change. No effective change is made during a terraform apply (an Update event happens on the deployment but no actual change) but the next terraform plan shows the same marked change
Steps to Reproduce
terraform plan or terraform apply
Screenshots
Debug Output
Plan output:
Output:# vra_deployment.vaultenterprise_rch2["vaultenterprisedr62002"] will be updated in-place
~ resource"vra_deployment""vaultenterprise_rch2" {
id="199e39ec-15df-47e4-acb9-c4b2e0d5e914"
~ inputs={
~ "tags" = jsonencode( # whitespace changes
[
{
key ="Backup"
value ="CloudEng_Daily"
},
]
)
# (9 unchanged elements hidden)
}
name="vaultenterprisedr62002"# (16 unchanged attributes hidden)# (1 unchanged block hidden)
}
Plan:0 to add, 24 to change, 0 to destroy.
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment
The text was updated successfully, but these errors were encountered:
I put the tf/provider version definition from the versions.tf file, once I validate the specific versions with the user who was experiencing this issue, I will update it.
I went through the provider code and I don't know either terraform or go well enough to fully pinpoint the issue, but I'm trying to learn both and if someone can help me pinpoint where this change is (if it's even in provider at all), I'm happy to start looking into a fix. Conceptually it seems like it's an issue with normalization so a well known class of problem to resolve.
I don't think it's an ordering issue, per se - flip the input order (below) and it doesn't show up. Somehow it's not normalizing the values between jsonencode and a flat string which gives the same result.
Code of Conduct
This project has a Code of Conduct that all participants are expected to understand and follow:
vRA Version
8.6.2
Terraform Version
Terraform v1.2.5
on darwin_amd64
vRA Terraform Provider Version
Affected Resource(s)
vra_deployment
I suspect others are affected due to the underlying issue, but this is the only verified resource
Terraform Configuration Files
Slightly sanitized, the inputs->tags is the relevant portion anyway
Expected Behavior
When there are no changes, terraform plan should show no changes
Actual Behavior
On every
terraform plan
, thetags
entries are marked for change. No effective change is made during aterraform apply
(an Update event happens on the deployment but no actual change) but the nextterraform plan
shows the same marked changeSteps to Reproduce
terraform plan
orterraform apply
Screenshots
Debug Output
Plan output:
The relevant portion of the state file says:
You can see that the tags are marked in different ways:
Changing the definition in the .tf file to use
jsonencode
for the tags eliminated the marked changes on every run.Community Note
The text was updated successfully, but these errors were encountered: