Skip to content

Commit cd8d5ef

Browse files
committed
Addressed PR comments, Added Linux Help Cmmnts, Updated Session Recordings
1 parent 8504d60 commit cd8d5ef

File tree

9 files changed

+851
-926
lines changed

9 files changed

+851
-926
lines changed

src/Compute/Compute.Test/ScenarioTests/VirtualMachineScaleSetTests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6001,14 +6001,14 @@ function Test-VirtualMachineScaleSetAddProxyAgentExtension
60016001

60026002
# Update vmss to add proxy agent extension
60036003
$VMSS = Get-AzVmss -ResourceGroupName $rgname -VMScaleSetName $vmssName
6004-
$VMSS = Set-AzVmssProxyAgentSetting -VirtualMachineScaleSet $VMSS -EnableProxyAgent $true -AddProxyAgentExtension $true
6004+
$VMSS = Set-AzVmssProxyAgentSetting -VirtualMachineScaleSet $VMSS -EnableProxyAgent $true -AddProxyAgentExtension $false
60056005
$vmssUpdated = Update-AzVmss -ResourceGroupName $rgname -Name $vmssName -VirtualMachineScaleSet $VMSS
60066006

60076007

60086008

60096009
# Validate
60106010
Assert-AreEqual $vmssUpdated.VirtualMachineProfile.SecurityProfile.ProxyAgentSettings.Enabled $true
6011-
Assert-AreEqual $vmssUpdated.VirtualMachineProfile.SecurityProfile.ProxyAgentSettings.AddProxyAgentExtension $true
6011+
Assert-AreEqual $vmssUpdated.VirtualMachineProfile.SecurityProfile.ProxyAgentSettings.AddProxyAgentExtension $false
60126012
}
60136013
finally
60146014
{

src/Compute/Compute.Test/SessionRecords/Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineScaleSetTests/TestVirtualMachineScaleSetAddProxyAgentExtension.json

Lines changed: 382 additions & 523 deletions
Large diffs are not rendered by default.

src/Compute/Compute.Test/SessionRecords/Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineTests/TestVirtualMachineAddProxyAgentExtension.json

Lines changed: 460 additions & 394 deletions
Large diffs are not rendered by default.

src/Compute/Compute/Generated/VirtualMachineScaleSet/Config/SetAzVmssProxyAgentSetting.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public class SetAzureVmssProxySetting : Microsoft.Azure.Commands.ResourceManager
7272
[Parameter(
7373
Mandatory = false,
7474
ValueFromPipelineByPropertyName = true,
75-
HelpMessage = "Specifies whether to add installation of the ProxyAgent extension.")]
75+
HelpMessage = "Specify whether to implicitly install the ProxyAgent Extension. This option is currently applicable only for Linux Os.")]
7676
public bool? AddProxyAgentExtension { get; set; }
7777

7878
public override void ExecuteCmdlet()

src/Compute/Compute/Manual/VirtualMachineScaleSetCreateOrUpdateMethod.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ public partial class NewAzureRmVmss : ComputeAutomationBaseCmdlet
296296
Mandatory = false,
297297
ValueFromPipelineByPropertyName = true,
298298
ParameterSetName = SimpleParameterSet,
299-
HelpMessage = "Specifies whether to add installation of the ProxyAgent extension.")]
299+
HelpMessage = "Specify whether to implicitly install the ProxyAgent Extension. This option is currently applicable only for Linux Os.")]
300300
public SwitchParameter AddProxyAgentExtension { get; set; }
301301

302302
private void ConfigureSecuritySettings()

src/Compute/Compute/Strategies/ComputeRp/VirtualMachineScaleSetStrategy.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ internal static ResourceConfig<VirtualMachineScaleSet> CreateVirtualMachineScale
115115
EncryptionAtHost = encryptionAtHost,
116116
UefiSettings = (enableVtpm != null || enableSecureBoot != null) ? new UefiSettings(enableSecureBoot, enableVtpm) : null,
117117
SecurityType = securityType,
118-
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enableProxyAgent) { AddProxyAgentExtension = addProxyAgentExtension } : null,
118+
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enabled: enableProxyAgent, addProxyAgentExtension: addProxyAgentExtension): null,
119119
},
120120
OsProfile = new VirtualMachineScaleSetOSProfile
121121
{
@@ -287,7 +287,7 @@ internal static ResourceConfig<VirtualMachineScaleSet> CreateVirtualMachineScale
287287
EncryptionAtHost = encryptionAtHost,
288288
UefiSettings = (enableVtpm != null || enableSecureBoot != null) ? new UefiSettings(enableSecureBoot, enableVtpm) : null,
289289
SecurityType = securityType,
290-
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enableProxyAgent) { AddProxyAgentExtension = addProxyAgentExtension } : null,
290+
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enabled: enableProxyAgent, addProxyAgentExtension: addProxyAgentExtension) : null,
291291
},
292292
OsProfile = new VirtualMachineScaleSetOSProfile
293293
{

src/Compute/Compute/Strategies/ComputeRp/VirtualMachineStrategy.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ public static ResourceConfig<VirtualMachine> CreateVirtualMachineConfig(
164164
EncryptionAtHost = encryptionAtHostPresent,
165165
UefiSettings = (enableVtpm != null || enableSecureBoot != null) ? new UefiSettings(enableSecureBoot, enableVtpm) : null,
166166
SecurityType = securityType,
167-
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enableProxyAgent) { AddProxyAgentExtension = addProxyAgentExtension } : null,
167+
ProxyAgentSettings = (enableProxyAgent != null || addProxyAgentExtension != null) ? new ProxyAgentSettings(enabled: enableProxyAgent, addProxyAgentExtension: addProxyAgentExtension): null,
168168
},
169169
CapacityReservation = string.IsNullOrEmpty(capacityReservationGroupId) ? null : new CapacityReservationProfile
170170
{

src/Compute/Compute/VirtualMachine/Config/SetAzVMProxyAgentSetting.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public class SetAzureVMProxySetting : Microsoft.Azure.Commands.ResourceManager.C
7676
[Parameter(
7777
Mandatory = false,
7878
ValueFromPipelineByPropertyName = true,
79-
HelpMessage = "Specifies whether to add installation of the ProxyAgent extension.")]
79+
HelpMessage = "Specify whether to implicitly install the ProxyAgent Extension. This option is currently applicable only for Linux Os.")]
8080
public bool? AddProxyAgentExtension { get; set; }
8181

8282
public override void ExecuteCmdlet()

src/Compute/Compute/VirtualMachine/Operation/NewAzureVMCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ public class NewAzureVMCommand : VirtualMachineBaseCmdlet
501501
Mandatory = false,
502502
ValueFromPipelineByPropertyName = true,
503503
ParameterSetName = SimpleParameterSet,
504-
HelpMessage = "Specifies whether to add installation of the ProxyAgent extension.")]
504+
HelpMessage = "Specify whether to implicitly install the ProxyAgent Extension. This option is currently applicable only for Linux Os.")]
505505
public SwitchParameter AddProxyAgentExtension { get; set; }
506506

507507
public override void ExecuteCmdlet()

0 commit comments

Comments
 (0)