When min_cound is = to max_count get error Error: max_count
must be >= min_count
when using azurerm_kubernetes_cluster_node_pool resource
#8944
Labels
Milestone
Community Note
Terraform (and AzureRM Provider) Version Terraform v = 0.13.3 azurerm provider v = 2.32.0
Affected Resource(s)
resource "azurerm_kubernetes_cluster_node_pool" "windows" {
count = var.enable_windows_pool ? 1 : 0
name = "win"
kubernetes_cluster_id = azurerm_kubernetes_cluster.gdo-aks.id
os_type = "Windows"
vm_size = var.windows_node_size
enable_auto_scaling = true
min_count = 1
max_count = 1
vnet_subnet_id = azurerm_subnet.aks-sn2.id
}
Actual Behavior
When this runs you will get the error Error:
max_count
must be >=min_count
As you can see that they are equal so this should run.
When you set the same for the default node_pool in the azurerm_kubernetes_cluster this will work fine.
Steps to Reproduce
In the azurerm_kubernetes_cluster_node_pool set min_count and max_count to teh same value
terraform apply
Important Factoids
I have looked through the code for azurerm_kubernetes_cluster_node_pool and see the following on lines 354 to line 356
Where as if you view this in the code for the azurerm_kubernetes_cluster resource you will see
Hense it works for the default node pool.
References
The text was updated successfully, but these errors were encountered: