Skip to content

Commit d5455f6

Browse files
authored
Added parameter NodeResourceGroup for New-AzAksCluster (#19214)
Co-authored-by: wyunchi-ms <[email protected]>
1 parent eadf9aa commit d5455f6

File tree

6 files changed

+319
-19
lines changed

6 files changed

+319
-19
lines changed

src/Aks/Aks/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
- Additional information about change #1
1919
-->
2020
## Upcoming Release
21+
* Added parameter `-NodeResourceGroup` for `New-AzAksCluster`. [#19014]
2122

2223
## Version 4.2.1
2324
* Removed the warning messages for MSGraph migration [#18856]

src/Aks/Aks/Commands/NewAzureRmAks.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,9 @@ public class NewAzureRmAks : CreateOrUpdateKubeBase
142142
HelpMessage = "Availability zones for cluster. Must use VirtualMachineScaleSets AgentPoolType.")]
143143
public string[] AvailabilityZone { get; set; }
144144

145+
[Parameter(Mandatory = false, HelpMessage = "The resource group containing agent pool.")]
146+
public string NodeResourceGroup { get; set; }
147+
145148
private AcsServicePrincipal acsServicePrincipal;
146149

147150
public override void ExecuteCmdlet()
@@ -350,6 +353,7 @@ private ManagedCluster BuildNewCluster()
350353
tags: TagsConversionHelper.CreateTagDictionary(Tag, true),
351354
dnsPrefix: DnsNamePrefix,
352355
kubernetesVersion: KubernetesVersion,
356+
nodeResourceGroup: NodeResourceGroup,
353357
agentPoolProfiles: new List<ManagedClusterAgentPoolProfile> { defaultAgentPoolProfile },
354358
linuxProfile: linuxProfile,
355359
windowsProfile: windowsProfile,

src/Aks/Aks/help/Get-AzAksNodePoolUpgradeProfile.md

Lines changed: 97 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
external help file:
2+
external help file: Az.Aks-help.xml
33
Module Name: Az.Aks
44
online version: https://docs.microsoft.com/powershell/module/az.aks/get-azaksnodepoolupgradeprofile
55
schema: 2.0.0
@@ -15,12 +15,16 @@ Gets the details of the upgrade profile for an agent pool with a specified resou
1515
### Get (Default)
1616
```
1717
Get-AzAksNodePoolUpgradeProfile -ClusterName <String> -NodePoolName <String> -ResourceGroupName <String>
18-
[-SubscriptionId <String[]>] [-DefaultProfile <PSObject>] [<CommonParameters>]
18+
[-SubscriptionId <String[]>] [-DefaultProfile <PSObject>] [-Break] [-HttpPipelineAppend <SendAsyncStep[]>]
19+
[-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>] [-ProxyCredential <PSCredential>]
20+
[-ProxyUseDefaultCredentials] [<CommonParameters>]
1921
```
2022

2123
### GetViaIdentity
2224
```
23-
Get-AzAksNodePoolUpgradeProfile -InputObject <IAksIdentity> [-DefaultProfile <PSObject>] [<CommonParameters>]
25+
Get-AzAksNodePoolUpgradeProfile -InputObject <IAksIdentity> [-DefaultProfile <PSObject>] [-Break]
26+
[-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-Proxy <Uri>]
27+
[-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [<CommonParameters>]
2428
```
2529

2630
## DESCRIPTION
@@ -43,6 +47,21 @@ Get Aks node pool upgrade profile with resource group name and cluster name.
4347

4448
## PARAMETERS
4549

50+
### -Break
51+
Wait for .NET debugger to attach
52+
53+
```yaml
54+
Type: System.Management.Automation.SwitchParameter
55+
Parameter Sets: (All)
56+
Aliases:
57+
58+
Required: False
59+
Position: Named
60+
Default value: False
61+
Accept pipeline input: False
62+
Accept wildcard characters: False
63+
```
64+
4665
### -ClusterName
4766
The name of the managed cluster resource.
4867
@@ -73,6 +92,36 @@ Accept pipeline input: False
7392
Accept wildcard characters: False
7493
```
7594
95+
### -HttpPipelineAppend
96+
SendAsync Pipeline Steps to be appended to the front of the pipeline
97+
98+
```yaml
99+
Type: Microsoft.Azure.PowerShell.Cmdlets.Aks.Runtime.SendAsyncStep[]
100+
Parameter Sets: (All)
101+
Aliases:
102+
103+
Required: False
104+
Position: Named
105+
Default value: None
106+
Accept pipeline input: False
107+
Accept wildcard characters: False
108+
```
109+
110+
### -HttpPipelinePrepend
111+
SendAsync Pipeline Steps to be prepended to the front of the pipeline
112+
113+
```yaml
114+
Type: Microsoft.Azure.PowerShell.Cmdlets.Aks.Runtime.SendAsyncStep[]
115+
Parameter Sets: (All)
116+
Aliases:
117+
118+
Required: False
119+
Position: Named
120+
Default value: None
121+
Accept pipeline input: False
122+
Accept wildcard characters: False
123+
```
124+
76125
### -InputObject
77126
Identity Parameter
78127
To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
@@ -104,6 +153,51 @@ Accept pipeline input: False
104153
Accept wildcard characters: False
105154
```
106155
156+
### -Proxy
157+
The URI for the proxy server to use
158+
159+
```yaml
160+
Type: System.Uri
161+
Parameter Sets: (All)
162+
Aliases:
163+
164+
Required: False
165+
Position: Named
166+
Default value: None
167+
Accept pipeline input: False
168+
Accept wildcard characters: False
169+
```
170+
171+
### -ProxyCredential
172+
Credentials for a proxy server to use for the remote call
173+
174+
```yaml
175+
Type: System.Management.Automation.PSCredential
176+
Parameter Sets: (All)
177+
Aliases:
178+
179+
Required: False
180+
Position: Named
181+
Default value: None
182+
Accept pipeline input: False
183+
Accept wildcard characters: False
184+
```
185+
186+
### -ProxyUseDefaultCredentials
187+
Use the default credentials for the proxy
188+
189+
```yaml
190+
Type: System.Management.Automation.SwitchParameter
191+
Parameter Sets: (All)
192+
Aliases:
193+
194+
Required: False
195+
Position: Named
196+
Default value: False
197+
Accept pipeline input: False
198+
Accept wildcard characters: False
199+
```
200+
107201
### -ResourceGroupName
108202
The name of the resource group.
109203
@@ -166,4 +260,3 @@ INPUTOBJECT `<IAksIdentity>`: Identity Parameter
166260
- `[SubscriptionId <String>]`: Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
167261

168262
## RELATED LINKS
169-

src/Aks/Aks/help/New-AzAksCluster.md

Lines changed: 21 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,12 @@ New-AzAksCluster [-NodeVmSetType <String>] [-NodeVnetSubnetID <String>] [-NodeMa
2424
[-NetworkPlugin <String>] [-NetworkPolicy <String>] [-PodCidr <String>] [-ServiceCidr <String>]
2525
[-DnsServiceIP <String>] [-DockerBridgeCidr <String>] [-NodePoolLabel <Hashtable>]
2626
[-AksCustomHeader <Hashtable>] [-LoadBalancerSku <String>] [-Force] [-GenerateSshKey] [-EnableNodePublicIp]
27-
[-NodePublicIPPrefixID <String>] [-AvailabilityZone <String[]>] [-ResourceGroupName] <String> [-Name] <String>
28-
[[-ServicePrincipalIdAndSecret] <PSCredential>] [-Location <String>] [-LinuxProfileAdminUserName <String>]
29-
[-DnsNamePrefix <String>] [-KubernetesVersion <String>] [-NodeName <String>] [-NodeMinCount <Int32>]
30-
[-NodeMaxCount <Int32>] [-EnableNodeAutoScaling] [-NodeCount <Int32>] [-NodeOsDiskSize <Int32>]
31-
[-NodeVmSize <String>] [-SshKeyValue <String>] [-AcrNameToAttach <String>] [-AsJob] [-Tag <Hashtable>]
27+
[-NodePublicIPPrefixID <String>] [-AvailabilityZone <String[]>] [-NodeResourceGroup <String>]
28+
[-ResourceGroupName] <String> [-Name] <String> [[-ServicePrincipalIdAndSecret] <PSCredential>]
29+
[-Location <String>] [-LinuxProfileAdminUserName <String>] [-DnsNamePrefix <String>]
30+
[-KubernetesVersion <String>] [-NodeName <String>] [-NodeMinCount <Int32>] [-NodeMaxCount <Int32>]
31+
[-EnableNodeAutoScaling] [-NodeCount <Int32>] [-NodeOsDiskSize <Int32>] [-NodeVmSize <String>]
32+
[-SshKeyValue <String>] [-AcrNameToAttach <String>] [-AsJob] [-Tag <Hashtable>]
3233
[-LoadBalancerAllocatedOutboundPort <Int32>] [-LoadBalancerManagedOutboundIpCount <Int32>]
3334
[-LoadBalancerOutboundIp <String[]>] [-LoadBalancerOutboundIpPrefix <String[]>]
3435
[-LoadBalancerIdleTimeoutInMinute <Int32>] [-ApiServerAccessAuthorizedIpRange <String[]>]
@@ -693,6 +694,21 @@ Accept pipeline input: False
693694
Accept wildcard characters: False
694695
```
695696
697+
### -NodeResourceGroup
698+
The resource group containing agent pool.
699+
700+
```yaml
701+
Type: System.String
702+
Parameter Sets: (All)
703+
Aliases:
704+
705+
Required: False
706+
Position: Named
707+
Default value: None
708+
Accept pipeline input: False
709+
Accept wildcard characters: False
710+
```
711+
696712
### -NodeScaleSetEvictionPolicy
697713
ScaleSetEvictionPolicy to be used to specify eviction policy for low priority virtual machine scale set. Default to Delete.
698714

src/Aks/Aks/help/Start-AzAksCluster.md

Lines changed: 98 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
external help file:
2+
external help file: Az.Aks-help.xml
33
Module Name: Az.Aks
44
online version: https://docs.microsoft.com/powershell/module/az.aks/start-azakscluster
55
schema: 2.0.0
@@ -15,13 +15,17 @@ Starts a Stopped Managed Cluster
1515
### Start (Default)
1616
```
1717
Start-AzAksCluster -Name <String> -ResourceGroupName <String> [-SubscriptionId <String>]
18-
[-DefaultProfile <PSObject>] [-AsJob] [-NoWait] [-PassThru] [-Confirm] [-WhatIf] [<CommonParameters>]
18+
[-DefaultProfile <PSObject>] [-AsJob] [-Break] [-HttpPipelineAppend <SendAsyncStep[]>]
19+
[-HttpPipelinePrepend <SendAsyncStep[]>] [-NoWait] [-PassThru] [-Proxy <Uri>]
20+
[-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm] [<CommonParameters>]
1921
```
2022

2123
### StartViaIdentity
2224
```
23-
Start-AzAksCluster -InputObject <IAksIdentity> [-DefaultProfile <PSObject>] [-AsJob] [-NoWait] [-PassThru]
24-
[-Confirm] [-WhatIf] [<CommonParameters>]
25+
Start-AzAksCluster -InputObject <IAksIdentity> [-DefaultProfile <PSObject>] [-AsJob] [-Break]
26+
[-HttpPipelineAppend <SendAsyncStep[]>] [-HttpPipelinePrepend <SendAsyncStep[]>] [-NoWait] [-PassThru]
27+
[-Proxy <Uri>] [-ProxyCredential <PSCredential>] [-ProxyUseDefaultCredentials] [-WhatIf] [-Confirm]
28+
[<CommonParameters>]
2529
```
2630

2731
## DESCRIPTION
@@ -60,6 +64,21 @@ Accept pipeline input: False
6064
Accept wildcard characters: False
6165
```
6266
67+
### -Break
68+
Wait for .NET debugger to attach
69+
70+
```yaml
71+
Type: System.Management.Automation.SwitchParameter
72+
Parameter Sets: (All)
73+
Aliases:
74+
75+
Required: False
76+
Position: Named
77+
Default value: False
78+
Accept pipeline input: False
79+
Accept wildcard characters: False
80+
```
81+
6382
### -DefaultProfile
6483
The credentials, account, tenant, and subscription used for communication with Azure.
6584
@@ -75,6 +94,36 @@ Accept pipeline input: False
7594
Accept wildcard characters: False
7695
```
7796
97+
### -HttpPipelineAppend
98+
SendAsync Pipeline Steps to be appended to the front of the pipeline
99+
100+
```yaml
101+
Type: Microsoft.Azure.PowerShell.Cmdlets.Aks.Runtime.SendAsyncStep[]
102+
Parameter Sets: (All)
103+
Aliases:
104+
105+
Required: False
106+
Position: Named
107+
Default value: None
108+
Accept pipeline input: False
109+
Accept wildcard characters: False
110+
```
111+
112+
### -HttpPipelinePrepend
113+
SendAsync Pipeline Steps to be prepended to the front of the pipeline
114+
115+
```yaml
116+
Type: Microsoft.Azure.PowerShell.Cmdlets.Aks.Runtime.SendAsyncStep[]
117+
Parameter Sets: (All)
118+
Aliases:
119+
120+
Required: False
121+
Position: Named
122+
Default value: None
123+
Accept pipeline input: False
124+
Accept wildcard characters: False
125+
```
126+
78127
### -InputObject
79128
Identity Parameter
80129
To construct, see NOTES section for INPUTOBJECT properties and create a hash table.
@@ -136,6 +185,51 @@ Accept pipeline input: False
136185
Accept wildcard characters: False
137186
```
138187
188+
### -Proxy
189+
The URI for the proxy server to use
190+
191+
```yaml
192+
Type: System.Uri
193+
Parameter Sets: (All)
194+
Aliases:
195+
196+
Required: False
197+
Position: Named
198+
Default value: None
199+
Accept pipeline input: False
200+
Accept wildcard characters: False
201+
```
202+
203+
### -ProxyCredential
204+
Credentials for a proxy server to use for the remote call
205+
206+
```yaml
207+
Type: System.Management.Automation.PSCredential
208+
Parameter Sets: (All)
209+
Aliases:
210+
211+
Required: False
212+
Position: Named
213+
Default value: None
214+
Accept pipeline input: False
215+
Accept wildcard characters: False
216+
```
217+
218+
### -ProxyUseDefaultCredentials
219+
Use the default credentials for the proxy
220+
221+
```yaml
222+
Type: System.Management.Automation.SwitchParameter
223+
Parameter Sets: (All)
224+
Aliases:
225+
226+
Required: False
227+
Position: Named
228+
Default value: False
229+
Accept pipeline input: False
230+
Accept wildcard characters: False
231+
```
232+
139233
### -ResourceGroupName
140234
The name of the resource group.
141235
@@ -229,4 +323,3 @@ INPUTOBJECT `<IAksIdentity>`: Identity Parameter
229323
- `[SubscriptionId <String>]`: Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
230324

231325
## RELATED LINKS
232-

0 commit comments

Comments
 (0)