Azure VM: windows_distribution_name

Is there a reference to help determine the correct value for windows_distribution_name? I know the SKU, but it doesn’t match up.

│ Error: Invalid index
│   on .terraform\modules\virtual-machine\ line 169, in resource "azurerm_windows_virtual_machine" "win_vm":
│  169:       version   = var.windows_distribution_list[lower(var.windows_distribution_name)]["version"]
│     ├────────────────
│     │ var.windows_distribution_list is map of object with 3 elements
│     │ var.windows_distribution_name is "2019-Datacenter-smalldisk"
│ The given key does not identify an element in this collection value.

Hi @sophware,

It seems that var.windows_distribution_name is a key for the map var.windows_distribution_list, which is a variable defined by you in this module and not something Terraform itself (or the AzureRM provider) provides.

It would be the responsibility of the caller of this module to provide consistent values for both windows_distribution_list and windows_distribution_name when calling the module.