Update-AzAksNodePool

Update node pool in a managed cluster.

Syntax

Update-AzAksNodePool
      -ResourceGroupName <String>
      -ClusterName <String>
      -Name <String>
      [-NodeCount <Int32>]
      [-NodeImageOnly]
      [-AsJob]
      [-Force]
      [-MaxSurge <String>]
      [-KubernetesVersion <String>]
      [-MinCount <Int32>]
      [-MaxCount <Int32>]
      [-EnableAutoScaling]
      [-Mode <String>]
      [-NodeLabel <Hashtable>]
      [-Tag <Hashtable>]
      [-NodeTaint <String[]>]
      [-AksCustomHeader <Hashtable>]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [-SubscriptionId <String>]
      [<CommonParameters>]
Update-AzAksNodePool
      -Name <String>
      -ClusterObject <PSKubernetesCluster>
      [-NodeCount <Int32>]
      [-NodeImageOnly]
      [-AsJob]
      [-Force]
      [-MaxSurge <String>]
      [-KubernetesVersion <String>]
      [-MinCount <Int32>]
      [-MaxCount <Int32>]
      [-EnableAutoScaling]
      [-Mode <String>]
      [-NodeLabel <Hashtable>]
      [-Tag <Hashtable>]
      [-NodeTaint <String[]>]
      [-AksCustomHeader <Hashtable>]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [-SubscriptionId <String>]
      [<CommonParameters>]
Update-AzAksNodePool
      -InputObject <PSNodePool>
      [-NodeCount <Int32>]
      [-NodeImageOnly]
      [-AsJob]
      [-Force]
      [-MaxSurge <String>]
      [-KubernetesVersion <String>]
      [-MinCount <Int32>]
      [-MaxCount <Int32>]
      [-EnableAutoScaling]
      [-Mode <String>]
      [-NodeLabel <Hashtable>]
      [-Tag <Hashtable>]
      [-NodeTaint <String[]>]
      [-AksCustomHeader <Hashtable>]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [-SubscriptionId <String>]
      [<CommonParameters>]
Update-AzAksNodePool
      -Id <String>
      [-NodeCount <Int32>]
      [-NodeImageOnly]
      [-AsJob]
      [-Force]
      [-MaxSurge <String>]
      [-KubernetesVersion <String>]
      [-MinCount <Int32>]
      [-MaxCount <Int32>]
      [-EnableAutoScaling]
      [-Mode <String>]
      [-NodeLabel <Hashtable>]
      [-Tag <Hashtable>]
      [-NodeTaint <String[]>]
      [-AksCustomHeader <Hashtable>]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [-SubscriptionId <String>]
      [<CommonParameters>]

Description

Update node pool in a managed cluster.

Examples

Example 1: Change minimun count to 5 for specified node pool

Update-AzAksNodePool -ResourceGroupName myResourceGroup -ClusterName myCluster -Name linuxpool -MinCount 5

Parameters

-AksCustomHeader

Aks custom headers

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-AsJob

Run cmdlet in the background

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ClusterName

The name of the managed cluster resource.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ClusterObject

The cluster object

Type:PSKubernetesCluster
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with Azure.

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-EnableAutoScaling

Whether to enable auto-scaler

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Force

Update node pool without prompt

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Id

Id of an node pool in managed Kubernetes cluster

Type:String
Aliases:ResourceId
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

A PSAgentPool object, normally passed through the pipeline.

Type:PSNodePool
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-KubernetesVersion

The version of Kubernetes to use for creating the cluster.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-MaxCount

Maximum number of nodes for auto-scaling

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-MaxSurge

The maximum number or percentage of nodes that ar surged during upgrade.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-MinCount

Minimum number of nodes for auto-scaling.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Mode

The pool mode

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Name

The name of the node pool.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-NodeCount

The number of nodes for the node pools.

Type:Int32
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-NodeImageOnly

Will only upgrade the node image of agent pools.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-NodeLabel

Node pool labels used for building Kubernetes network.

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-NodeTaint

The node taints added to new nodes during node pool create and scale

Type:String[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ResourceGroupName

The name of the resource group.

Type:String
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-SubscriptionId

The ID of the subscription. By default, cmdlets are executed in the subscription that is set in the current context. If the user specifies another subscription, the current cmdlet is executed in the subscription specified by the user. Overriding subscriptions only take effect during the lifecycle of the current cmdlet. It does not change the subscription in the context, and does not affect subsequent cmdlets.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Tag

The tags to be persisted on the agent pool virtual machine scale set.

Type:Hashtable
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

PSNodePool

String

Outputs

PSNodePool