Hi all,
I have read some posts about this but I would like another opinion. We have some old v0.11 scripts that are not upgraded. Example section is:
resource "azurerm_kubernetes_cluster" "k8s" {
name = var.aks_name
location = "${data.azurerm_resource_group.main.location}"
dns_prefix = "${var.k8s_dns_prefix}-${data.azurerm_resource_group.main.name}"
resource_group_name = "${data.azurerm_resource_group.main.name}"
node_resource_group = "Nodes_${data.azurerm_resource_group.main.name}"
kubernetes_version = var.kubernetes_version
.
.
.
Am I right in thinking that for those parameters that refer to a single variable, I should remove the "${....}"
, and for those that use additional text or combined variables, I should leave them alone?
As an example of the above as an updated version, would this be correct:
resource "azurerm_kubernetes_cluster" "k8s" {
name = var.aks_name
location = data.azurerm_resource_group.main.location
dns_prefix = "${var.k8s_dns_prefix}-${data.azurerm_resource_group.main.name}"
resource_group_name = data.azurerm_resource_group.main.name
node_resource_group = "Nodes_${data.azurerm_resource_group.main.name}"
kubernetes_version = var.kubernetes_version
.
.
.