Hi,
Finally getting around to upgrading my terraform (shame on me). Going from 11 → 0.13.5 with a stop at 12 along the way. The upgrade went pretty smoothly but now I am getting the Interpolation-only expressions are deprecated warning.
I have about 300 instances of this and I have two questions:
- Is there a recommended automated way to fix these issues (a.k.a. terraform fmt) ? I would like to avoid having to manually having to update 400 different spots in the code.
- I assume that just removing the “${}” will still allow it to work as before? The var.varname will still resolve?
Thank you very much.
Warning: Interpolation-only expressions are deprecated
on modules/account/main.tf line 15, in resource “kubernetes_deployment” “account_domain”:
15: namespace = “${var.applicationNamespace}”Terraform 0.11 and earlier required all non-constant expressions to be
provided via interpolation syntax, but this pattern is now deprecated. To
silence this warning, remove the “${ sequence from the start and the }”
sequence from the end of this expression, leaving just the inner expression.Template interpolation syntax is still used to construct strings from
expressions when the template includes multiple interpolation sequences or a
mixture of literal strings and interpolations. This deprecation applies only
to templates that consist entirely of a single interpolation sequence.(and 284 more similar warnings elsewhere)