terraform-provider-kops
terraform-provider-kops copied to clipboard
Sort external policies
Would it be possible to sort the external policies in the state to make those kinds of changes go away?
# module.k8s.kops_cluster.k8s will be updated in-place
~ resource "kops_cluster" "k8s" {
id = "k8s.xxx.yy"
name = "k8s.xxx.yy"
~ revision = 37 -> 38
# (22 unchanged attributes hidden)
~ external_policies {
~ key = "node" -> "master"
# (1 unchanged attribute hidden)
}
~ external_policies {
~ key = "master" -> "node"
# (1 unchanged attribute hidden)
}
# (22 unchanged blocks hidden)
}
I guess it changed in the config ?
@argoyle does the diff happens when the input config is identical ?
It's not always changing and trigger an update, that's why I think it might be due to Go's handling of maps and non-deterministic order when ranging over them.
So you confirm the input terraform config did not change ? I will give a look, could be because of go maps indeed.
I haven't changed anything related to external policies. It might be other changes that trigger the actual update though. This time it was due to updating to 1.25.1 of the provider only, no other changes.