Share via


AgentPool Class

Definition

Agent Pool.

[Microsoft.Rest.Serialization.JsonTransformation]
public class AgentPool : Microsoft.Azure.Management.ContainerService.Models.SubResource
[<Microsoft.Rest.Serialization.JsonTransformation>]
type AgentPool = class
    inherit SubResource
Public Class AgentPool
Inherits SubResource
Inheritance
AgentPool
Attributes

Constructors

AgentPool()

Initializes a new instance of the AgentPool class.

AgentPool(String, String, String, String, String, PowerState, KubeletConfig, CreationData, Nullable<Int32>, String, Nullable<Int32>, String, String, String, String, Nullable<Int32>, String, Nullable<Int32>, Nullable<Int32>, Nullable<Boolean>, String, String, String, String, String, String, AgentPoolUpgradeSettings, String, IList<String>, Nullable<Boolean>, String, String, String, Nullable<Double>, IDictionary<String,String>, IDictionary<String,String>, IList<String>, String, LinuxOSConfig, Nullable<Boolean>, Nullable<Boolean>, Nullable<Boolean>, String, String)

Initializes a new instance of the AgentPool class.

Properties

AgentPoolType

Gets or sets the type of Agent Pool. Possible values include: 'VirtualMachineScaleSets', 'AvailabilitySet'

AvailabilityZones

Gets or sets the list of Availability zones to use for nodes. This can only be specified if the AgentPoolType property is 'VirtualMachineScaleSets'.

Count

Gets or sets number of agents (VMs) to host docker containers. Allowed values must be in the range of 0 to 1000 (inclusive) for user pools and in the range of 1 to 1000 (inclusive) for system pools. The default value is 1.

CreationData

Gets or sets creationData to be used to specify the source Snapshot ID if the node pool will be created/upgraded using a snapshot.

CurrentOrchestratorVersion

Gets if orchestratorVersion is a fully specified version (major.minor.patch), this field will be exactly equal to it. If orchestratorVersion is (major.minor), this field will contain the full (major.minor.patch) version being used.

EnableAutoScaling

Gets or sets whether to enable auto-scaler

EnableEncryptionAtHost

Gets or sets this is only supported on certain VM sizes and in certain Azure regions. For more information, see: https://docs.microsoft.com/azure/aks/enable-host-encryption

EnableFips

Gets or sets see Add a FIPS-enabled node pool for more details.

EnableNodePublicIP

Gets or sets some scenarios may require nodes in a node pool to receive their own dedicated public IP addresses. A common scenario is for gaming workloads, where a console needs to make a direct connection to a cloud virtual machine to minimize hops. For more information see assigning a public IP per node. The default is false.

EnableUltraSsd

Gets or sets whether to enable UltraSSD

GpuInstanceProfile

Gets or sets gPUInstanceProfile to be used to specify GPU MIG instance profile for supported GPU VM SKU. Possible values include: 'MIG1g', 'MIG2g', 'MIG3g', 'MIG4g', 'MIG7g'

HostGroupId

Gets or sets this is of the form: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/hostGroups/{hostGroupName}. For more information see Azure dedicated hosts.

Id

Gets resource ID.

(Inherited from SubResource)
KubeletConfig

Gets or sets the Kubelet configuration on the agent pool nodes.

KubeletDiskType

Gets or sets determines the placement of emptyDir volumes, container runtime data root, and Kubelet ephemeral storage. Possible values include: 'OS', 'Temporary'

LinuxOSConfig

Gets or sets the OS configuration of Linux agent nodes.

MaxCount

Gets or sets the maximum number of nodes for auto-scaling

MaxPods

Gets or sets the maximum number of pods that can run on a node.

MinCount

Gets or sets the minimum number of nodes for auto-scaling

Mode

Gets or sets a cluster must have at least one 'System' Agent Pool at all times. For additional information on agent pool restrictions and best practices, see: https://docs.microsoft.com/azure/aks/use-system-pools Possible values include: 'System', 'User'

Name

Gets the name of the resource that is unique within a resource group. This name can be used to access the resource.

(Inherited from SubResource)
NodeImageVersion

Gets the version of node image

NodeLabels

Gets or sets the node labels to be persisted across all nodes in agent pool.

NodePublicIPPrefixId

Gets or sets this is of the form: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/publicIPPrefixes/{publicIPPrefixName}

NodeTaints

Gets or sets the taints added to new nodes during node pool create and scale. For example, key=value:NoSchedule.

OrchestratorVersion

Gets or sets both patch version (major.minor.patch) (e.g. 1.20.13) and (major.minor) (e.g. 1.20) are supported. When (major.minor) is specified, the latest supported GA patch version is chosen automatically. Updating the cluster with the same (major.minor) once it has been created (e.g. 1.14.x -) 1.14) will not trigger an upgrade, even if a newer patch version is available. As a best practice, you should upgrade all node pools in an AKS cluster to the same Kubernetes version. The node pool version must have the same major version as the control plane. The node pool minor version must be within two minor versions of the control plane version. The node pool version cannot be greater than the control plane version. For more information see upgrading a node pool.

OSDiskSizeGb

Gets or sets oS Disk Size in GB to be used to specify the disk size for every machine in the master/agent pool. If you specify 0, it will apply the default osDisk size according to the vmSize specified.

OSDiskType

Gets or sets the default is 'Ephemeral' if the VM supports it and has a cache disk larger than the requested OSDiskSizeGB. Otherwise, defaults to 'Managed'. May not be changed after creation. For more information see Ephemeral OS. Possible values include: 'Managed', 'Ephemeral'

OSSku

Gets or sets specifies the OS SKU used by the agent pool. The default is Ubuntu if OSType is Linux. The default is Windows2019 when Kubernetes <= 1.24 or Windows2022 when Kubernetes >= 1.25 if OSType is Windows. Possible values include: 'Ubuntu', 'AzureLinux', 'CBLMariner', 'Windows2019', 'Windows2022'

OSType

Gets or sets the operating system type. The default is Linux. Possible values include: 'Linux', 'Windows'

PodSubnetId

Gets or sets if omitted, pod IPs are statically assigned on the node subnet (see vnetSubnetID for more details). This is of the form: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{virtualNetworkName}/subnets/{subnetName}

PowerState

Gets or sets when an Agent Pool is first created it is initially Running. The Agent Pool can be stopped by setting this field to Stopped. A stopped Agent Pool stops all of its VMs and does not accrue billing charges. An Agent Pool can only be stopped if it is Running and provisioning state is Succeeded

ProvisioningState

Gets the current deployment or provisioning state.

ProximityPlacementGroupId

Gets or sets the ID for Proximity Placement Group.

ScaleDownMode

Gets or sets this also effects the cluster autoscaler behavior. If not specified, it defaults to Delete. Possible values include: 'Delete', 'Deallocate'

ScaleSetEvictionPolicy

Gets or sets this cannot be specified unless the scaleSetPriority is 'Spot'. If not specified, the default is 'Delete'. Possible values include: 'Delete', 'Deallocate'

ScaleSetPriority

Gets or sets the Virtual Machine Scale Set priority. If not specified, the default is 'Regular'. Possible values include: 'Spot', 'Regular'

SpotMaxPrice

Gets or sets possible values are any decimal value greater than zero or -1 which indicates the willingness to pay any on-demand price. For more details on spot pricing, see spot VMs pricing

Tags

Gets or sets the tags to be persisted on the agent pool virtual machine scale set.

Type

Gets resource type

(Inherited from SubResource)
UpgradeSettings

Gets or sets settings for upgrading the agentpool

VMSize

Gets or sets vM size availability varies by region. If a node contains insufficient compute resources (memory, cpu, etc) pods might fail to run correctly. For more details on restricted VM sizes, see: https://docs.microsoft.com/azure/aks/quotas-skus-regions

VnetSubnetId

Gets or sets if this is not specified, a VNET and subnet will be generated and used. If no podSubnetID is specified, this applies to nodes and pods, otherwise it applies to just nodes. This is of the form: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/virtualNetworks/{virtualNetworkName}/subnets/{subnetName}

WorkloadRuntime

Gets or sets determines the type of workload a node can run. Possible values include: 'OCIContainer', 'WasmWasi'

Methods

Validate()

Validate the object.

Applies to