Microsoft.ContainerService managedClusters/agentPools 2021-03-01

The managedClusters/agentPools resource type can be deployed to: Resource groups.

To learn about resource group deployments, see Bicep or ARM template.

Template format

To create a Microsoft.ContainerService/managedClusters/agentPools resource, add the following Bicep or JSON to your template.

resource symbolicname 'Microsoft.ContainerService/managedClusters/agentPools@2021-03-01' = {
  name: 'string'
  parent: parentSymbolicName
  properties: {
    availabilityZones: [ 'string' ]
    count: int
    enableAutoScaling: bool
    enableEncryptionAtHost: bool
    enableFIPS: bool
    enableNodePublicIP: bool
    gpuInstanceProfile: 'string'
    kubeletConfig: {
      allowedUnsafeSysctls: [ 'string' ]
      containerLogMaxFiles: int
      containerLogMaxSizeMB: int
      cpuCfsQuota: bool
      cpuCfsQuotaPeriod: 'string'
      cpuManagerPolicy: 'string'
      failSwapOn: bool
      imageGcHighThreshold: int
      imageGcLowThreshold: int
      podMaxPids: int
      topologyManagerPolicy: 'string'
    kubeletDiskType: 'string'
    linuxOSConfig: {
      swapFileSizeMB: int
      sysctls: {
        fsAioMaxNr: int
        fsFileMax: int
        fsInotifyMaxUserWatches: int
        fsNrOpen: int
        kernelThreadsMax: int
        netCoreNetdevMaxBacklog: int
        netCoreOptmemMax: int
        netCoreRmemDefault: int
        netCoreRmemMax: int
        netCoreSomaxconn: int
        netCoreWmemDefault: int
        netCoreWmemMax: int
        netIpv4IpLocalPortRange: 'string'
        netIpv4NeighDefaultGcThresh1: int
        netIpv4NeighDefaultGcThresh2: int
        netIpv4NeighDefaultGcThresh3: int
        netIpv4TcpFinTimeout: int
        netIpv4TcpkeepaliveIntvl: int
        netIpv4TcpKeepaliveProbes: int
        netIpv4TcpKeepaliveTime: int
        netIpv4TcpMaxSynBacklog: int
        netIpv4TcpMaxTwBuckets: int
        netIpv4TcpTwReuse: bool
        netNetfilterNfConntrackBuckets: int
        netNetfilterNfConntrackMax: int
        vmMaxMapCount: int
        vmSwappiness: int
        vmVfsCachePressure: int
      transparentHugePageDefrag: 'string'
      transparentHugePageEnabled: 'string'
    maxCount: int
    maxPods: int
    minCount: int
    mode: 'string'
    nodeLabels: {}
    nodePublicIPPrefixID: 'string'
    nodeTaints: [ 'string' ]
    orchestratorVersion: 'string'
    osDiskSizeGB: int
    osDiskType: 'string'
    osSKU: 'string'
    osType: 'string'
    podSubnetID: 'string'
    proximityPlacementGroupID: 'string'
    scaleSetEvictionPolicy: 'string'
    scaleSetPriority: 'string'
    spotMaxPrice: int
    tags: {
      tagName1: 'tagValue1'
      tagName2: 'tagValue2'
    type: 'string'
    upgradeSettings: {
      maxSurge: 'string'
    vmSize: 'string'
    vnetSubnetID: 'string'

Property values


Name Description Value
type The resource type

For Bicep, set this value in the resource declaration.
apiVersion The resource api version

For Bicep, set this value in the resource declaration.
name The resource name

See how to set names and types for child resources in Bicep or JSON ARM templates.
string (required)
parent In Bicep, you can specify the parent resource for a child resource. You only need to add this property when the child resource is declared outside of the parent resource.

For more information, see Child resource outside parent resource.
properties Properties for the container service agent pool profile. ManagedClusterAgentPoolProfileProperties


Name Description Value
availabilityZones Availability zones for nodes. Must use VirtualMachineScaleSets AgentPoolType. string[]
count Number of agents (VMs) to host docker containers. Allowed values must be in the range of 0 to 100 (inclusive) for user pools and in the range of 1 to 100 (inclusive) for system pools. The default value is 1. int
enableAutoScaling Whether to enable auto-scaler bool
enableEncryptionAtHost Whether to enable EncryptionAtHost bool
enableFIPS Whether to use FIPS enabled OS bool
enableNodePublicIP Enable public IP for nodes bool
gpuInstanceProfile GPUInstanceProfile to be used to specify GPU MIG instance profile for supported GPU VM SKU. Supported values are MIG1g, MIG2g, MIG3g, MIG4g and MIG7g. 'MIG1g'
kubeletConfig Kubelet configurations of agent nodes. KubeletConfig
kubeletDiskType KubeletDiskType determines the placement of emptyDir volumes, container runtime data root, and Kubelet ephemeral storage. Allowed values: 'OS', 'Temporary' (preview). 'OS'
linuxOSConfig OS configurations of Linux agent nodes. LinuxOSConfig
maxCount Maximum number of nodes for auto-scaling int
maxPods Maximum number of pods that can run on a node. int
minCount Minimum number of nodes for auto-scaling int
mode AgentPoolMode represents mode of an agent pool. 'System'
nodeLabels Agent pool node labels to be persisted across all nodes in agent pool. object
nodePublicIPPrefixID Public IP Prefix ID. VM nodes use IPs assigned from this Public IP Prefix. string
nodeTaints Taints added to new nodes during node pool create and scale. For example, key=value:NoSchedule. string[]
orchestratorVersion Version of orchestrator specified when creating the managed cluster. string
osDiskSizeGB OS Disk Size in GB to be used to specify the disk size for every machine in this master/agent pool. If you specify 0, it will apply the default osDisk size according to the vmSize specified. int
osDiskType OSDiskType represents the type of an OS disk on an agent pool. 'Ephemeral'
osSKU OsSKU to be used to specify os sku. Choose from Ubuntu(default) and CBLMariner for Linux OSType. Not applicable to Windows OSType. 'CBLMariner'
osType OsType to be used to specify os type. Choose from Linux and Windows. Default to Linux. 'Linux'
podSubnetID specifies a subnet's resource id with subscription, resource group, vnet and subnet name string
proximityPlacementGroupID The ID for Proximity Placement Group. string
scaleSetEvictionPolicy ScaleSetEvictionPolicy to be used to specify eviction policy for Spot virtual machine scale set. Default to Delete. 'Deallocate'
scaleSetPriority ScaleSetPriority to be used to specify virtual machine scale set priority. Default to regular. 'Regular'
spotMaxPrice SpotMaxPrice to be used to specify the maximum price you are willing to pay in US Dollars. Possible values are any decimal value greater than zero or -1 which indicates default price to be up-to on-demand. int
tags Agent pool tags to be persisted on the agent pool virtual machine scale set. Dictionary of tag names and values. See Tags in templates
type AgentPoolType represents types of an agent pool. 'AvailabilitySet'
upgradeSettings Settings for upgrading an agentpool AgentPoolUpgradeSettings
vmSize Size of agent VMs. string
vnetSubnetID specifies a subnet's resource id with subscription, resource group, vnet and subnet name string


Name Description Value
allowedUnsafeSysctls Allowlist of unsafe sysctls or unsafe sysctl patterns (ending in *). string[]
containerLogMaxFiles The maximum number of container log files that can be present for a container. The number must be ≥ 2. int
containerLogMaxSizeMB The maximum size (e.g. 10Mi) of container log file before it is rotated. int
cpuCfsQuota Enable CPU CFS quota enforcement for containers that specify CPU limits. bool
cpuCfsQuotaPeriod Sets CPU CFS quota period value. string
cpuManagerPolicy CPU Manager policy to use. string
failSwapOn If set to true it will make the Kubelet fail to start if swap is enabled on the node. bool
imageGcHighThreshold The percent of disk usage after which image garbage collection is always run. int
imageGcLowThreshold The percent of disk usage before which image garbage collection is never run. int
podMaxPids The maximum number of processes per pod. int
topologyManagerPolicy Topology Manager policy to use. string


Name Description Value
swapFileSizeMB SwapFileSizeMB specifies size in MB of a swap file will be created on each node. int
sysctls Sysctl settings for Linux agent nodes. SysctlConfig
transparentHugePageDefrag Transparent Huge Page defrag configuration. string
transparentHugePageEnabled Transparent Huge Page enabled configuration. string


Name Description Value
fsAioMaxNr Sysctl setting fs.aio-max-nr. int
fsFileMax Sysctl setting fs.file-max. int
fsInotifyMaxUserWatches Sysctl setting fs.inotify.max_user_watches. int
fsNrOpen Sysctl setting fs.nr_open. int
kernelThreadsMax Sysctl setting kernel.threads-max. int
netCoreNetdevMaxBacklog Sysctl setting net.core.netdev_max_backlog. int
netCoreOptmemMax Sysctl setting net.core.optmem_max. int
netCoreRmemDefault Sysctl setting net.core.rmem_default. int
netCoreRmemMax Sysctl setting net.core.rmem_max. int
netCoreSomaxconn Sysctl setting net.core.somaxconn. int
netCoreWmemDefault Sysctl setting net.core.wmem_default. int
netCoreWmemMax Sysctl setting net.core.wmem_max. int
netIpv4IpLocalPortRange Sysctl setting net.ipv4.ip_local_port_range. string
netIpv4NeighDefaultGcThresh1 Sysctl setting net.ipv4.neigh.default.gc_thresh1. int
netIpv4NeighDefaultGcThresh2 Sysctl setting net.ipv4.neigh.default.gc_thresh2. int
netIpv4NeighDefaultGcThresh3 Sysctl setting net.ipv4.neigh.default.gc_thresh3. int
netIpv4TcpFinTimeout Sysctl setting net.ipv4.tcp_fin_timeout. int
netIpv4TcpkeepaliveIntvl Sysctl setting net.ipv4.tcp_keepalive_intvl. int
netIpv4TcpKeepaliveProbes Sysctl setting net.ipv4.tcp_keepalive_probes. int
netIpv4TcpKeepaliveTime Sysctl setting net.ipv4.tcp_keepalive_time. int
netIpv4TcpMaxSynBacklog Sysctl setting net.ipv4.tcp_max_syn_backlog. int
netIpv4TcpMaxTwBuckets Sysctl setting net.ipv4.tcp_max_tw_buckets. int
netIpv4TcpTwReuse Sysctl setting net.ipv4.tcp_tw_reuse. bool
netNetfilterNfConntrackBuckets Sysctl setting net.netfilter.nf_conntrack_buckets. int
netNetfilterNfConntrackMax Sysctl setting net.netfilter.nf_conntrack_max. int
vmMaxMapCount Sysctl setting vm.max_map_count. int
vmSwappiness Sysctl setting vm.swappiness. int
vmVfsCachePressure Sysctl setting vm.vfs_cache_pressure. int


Name Description Value
maxSurge Count or percentage of additional nodes to be added during upgrade. If empty uses AKS default string

Quickstart templates

The following quickstart templates deploy this resource type.

Template Description
Deploy an AKS cluster for Azure ML

Deploy to Azure
This template allows you to deploy an entreprise compliant AKS cluster which can be attached to Azure ML