0

I’m trying to create an Azure Kubernetes Service (AKS) Automatic cluster with my own custom node pool configuration, such as specifying:

VM size (Standard_D8s_v3)

Node count or autoscaler range

I followed the official documentation and sample scripts like this:

az aks create \
  --resource-group $RESOURCE_GROUP_AKSAUTO \
  --name $CLUSTER_NAME \
  --location $LOCATION \
  --apiserver-subnet-id "/subscriptions/${AZ_SUBSCRIPTION_ID}/resourceGroups/$RESOURCE_GROUP_AKSAUTO/providers/Microsoft.Network/virtualNetworks/${VNET_NAME}/subnets/apiServerSubnet" \
  --vnet-subnet-id "/subscriptions/${AZ_SUBSCRIPTION_ID}/resourceGroups/$RESOURCE_GROUP_AKSAUTO/providers/Microsoft.Network/virtualNetworks/${VNET_NAME}/subnets/clusterSubnet" \
  --assign-identity "/subscriptions/${AZ_SUBSCRIPTION_ID}/resourceGroups/$RESOURCE_GROUP_AKSAUTO/providers/Microsoft.ManagedIdentity/userAssignedIdentities/${IDENTITY_NAME}" \
  --sku automatic \
  --node-count 2 \
  --node-vm-size Standard_D8s_v3 \
  --enable-cluster-autoscaler --min-count 1 --max-count 5 \
  --no-ssh-key

But running this I get this error:

ERROR: (OperationNotAllowed) .properties.nodeProvisioningProfile.mode cannot be Auto unless all AgentPools have property .properties.enableAutoScaling set to one of [false]. Code: OperationNotAllowed

Even if I remove autoscaler flags, the cluster still doesn’t seem to allow customizing the node pool or VM size.

Is it currently possible to create an AKS Automatic cluster with custom node pool size or VM type, using either Azure CLI or Bicep? If not, is there any workaround or roadmap for supporting this feature?

1 Answer 1

0

to answer your question, yes it is possible to use a custom node size, but no, it is not possible to use a custom node count. This makes sense, because from the documentation:

Node management is automatically handled without the need for manual node pool creation. Scaling is seamless, with nodes created based on workload requests.

So, as I read this, the number of nodes is going to be based on the workload.

Using the CLI, I managed to create a cluster with the automatic sku using the following command:

az aks create `
  --resource-group $rg `
  --name $aks `
  --location $loc `
  --sku automatic `
  --node-vm-size Standard_D4pds_v6 `
  --no-ssh-key

Note that because of subscription cpu quotas I used a different vm size.

Update: It eventually created 3 nodes within the cluster of indeed Standard_D4pds_v6

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.