it throws the error "Failed to check ruleset; failed to check "azurerm_automation_account_invalid_sku_name" rule: main_base.tf:71,11-42: Incorrect value type; Invalid expression value: number required., and 1 other diagnostic(s)"
error is misleading had an issue with other terraform logic.
changed "count = var.testing == true ? [0] : [1]" to "count = var.testing == "true" ? 0 : 1"
Tflint version & ruleset version:
While running tflint over the following configuration:
" resource "azurerm_automation_account" "aa_wipe" { name = "aa-wipe-${trim(data.azurerm_subscription.current.display_name, "azc")}-${local.random}" location = azurerm_resource_group.rg.location resource_group_name = azurerm_resource_group.rg.name public_network_access_enabled = true sku_name = "Basic"
identity { type = "SystemAssigned" }
} "
it throws the error "Failed to check ruleset; failed to check "azurerm_automation_account_invalid_sku_name" rule: main_base.tf:71,11-42: Incorrect value type; Invalid expression value: number required., and 1 other diagnostic(s)"
terraform docs for the azurerm provider: https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/automation_account#sku_name
Tflint docs: https://github.com/terraform-linters/tflint-ruleset-azurerm/blob/master/docs/rules/azurerm_automation_account_invalid_sku_name.md
this looks like an bug that as both documentations and the code sku_name match.