Terraform v0.12.12
~> 0.10
resource "helm_release" "service" {
name = "service"
chart = "service"
version = "0.1.7"
repository = module.k8s.helm_repository_name
set {
name = "image.tag"
value = "latest"
}
}
A diff should be detected if settings of the release are modified outside of Terraform.
The helm provider does not detect changes to the release done outside of Terraform.
terraform apply
$ helm get values service
image:
tag: latest # <-- Value as set in terraform
helm upgrade service service --reuse-values --set image.tag=test
$ helm get values service
image:
tag: test # <-- Value in the deployed release changed
terraform apply (Should detect the change done on the release when refreshing the state)
...
helm_release.service: Refreshing state... [id=service]
...
Apply complete! Resources: 0 added, 0 changed, 0 destroyed.
Just ran into this, and it is very annoying. For a workaround, I did this:
set {
name = "valuesChecksum"
value = filemd5("${path.module}/values-production.yaml")
}
If edit resources created by helm directly, they also will be skipped, because values/release file not changed
Most helpful comment
Just ran into this, and it is very annoying. For a workaround, I did this: