Skip to content

Commit d1162fe

Browse files
authored
Merge branch 'main' into master
2 parents 43827c8 + 5b8b7c6 commit d1162fe

File tree

74 files changed

+5597
-107
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

74 files changed

+5597
-107
lines changed

documentation/development-docs/common-assemblies.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,11 @@ For further reading, please visit https://docs.microsoft.com/en-us/dotnet/standa
2525
5. Extract DLL file in nuget package folder `lib/net461` (alternatively, `netstandard2.0`) of `Azure.Core` and changed dependencies and copy them to `src/lib/NetFxPreloadAssemblies`.
2626
6. Update assembly version of `Azure.Core` and changed dependencies to .NET Framework in `/src/Accounts/Authentication/Utilities/CustomAssemblyResolver.cs`.
2727
7. Verify built `Az.Accounts` can work with existing Azure PowerShell modules on PowerShell 7 and Windows PowerShell.
28-
- Import module into PowerShell 7 or Windows PowerShell.
29-
```powershell
30-
Import-Module .\artifacts\Release\Az.Accounts\Az.Accounts.psd1
31-
```
28+
- Import module into PowerShell 7 or Windows PowerShell, and ensure there is no error in verbose output
29+
```powershell
30+
$VerbosePreference = "Continue"
31+
Import-Module .\artifacts\Release\Az.Accounts\Az.Accounts.psd1
32+
```
3233
- Connect to Azure and switch to your test subscription
3334
```powershell
3435
Connect-AzAccount

src/Accounts/Accounts/AzureRmAlias/Mappings.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2068,6 +2068,10 @@
20682068
"Remove-AzSearchQueryKey": "Remove-AzureRmSearchQueryKey"
20692069
},
20702070
"Az.Security": {
2071+
"New-AzAlertsSuppressionRuleScope": "New-AzureRmAlertsSuppressionRuleScope",
2072+
"Get-AzAlertsSuppressionRule": "Get-AzureRmAlertsSuppressionRule",
2073+
"Set-AzAlertsSuppressionRule": "Set-AzureRmAlertsSuppressionRule",
2074+
"Remove-AzAlertsSuppressionRule": "Remove-AzureRmAlertsSuppressionRule",
20712075
"Get-AzSecurityAlert": "Get-AzureRmSecurityAlert",
20722076
"Set-AzSecurityAlert": "Set-AzureRmSecurityAlert",
20732077
"Get-AzSecurityAutoProvisioningSetting": "Get-AzureRmSecurityAutoProvisioningSetting",

src/Accounts/Accounts/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
-->
2020

2121
## Upcoming Release
22+
* Upgraded System.Reflection.DispatchProxy on Windows PowerShell [#17856]
2223

2324
## Version 2.7.6
2425
* Upgraded Microsoft.Rest.ClientRuntime to 2.3.24

src/Accounts/Authentication/Utilities/CustomAssemblyResolver.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public static class CustomAssemblyResolver
3838
{"System.Net.Http.WinHttpHandler", new Version("4.0.2.0")},
3939
{"System.Numerics.Vectors", new Version("4.1.4.0")},
4040
{"System.Private.ServiceModel", new Version("4.7.0.0")}, //used by Compute
41-
{"System.Reflection.DispatchProxy", new Version("4.0.3.0")},
41+
{"System.Reflection.DispatchProxy", new Version("4.0.4.0")},
4242
{"System.Runtime.CompilerServices.Unsafe", new Version("4.0.6.0")},
4343
{"System.Security.AccessControl", new Version("4.1.1.0")},
4444
{"System.Security.Cryptography.Cng", new Version("4.3.0.0")},

src/Aks/Aks/Az.Aks.psd1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ CmdletsToExport = 'Get-AzAksCluster', 'New-AzAksCluster', 'Remove-AzAksCluster',
8989
# VariablesToExport = @()
9090

9191
# Aliases to export from this module, for best performance, do not use wildcards and do not delete the entry, use an empty array if there are no aliases to export.
92-
AliasesToExport = 'Get-AzAks', 'New-AzAks', 'Remove-AzAks', 'Set-AzAks'
92+
AliasesToExport = @()
9393

9494
# DSC resources to export from this module
9595
# DscResourcesToExport = @()

src/Aks/Aks/ChangeLog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,11 @@
1818
- Additional information about change #1
1919
-->
2020
## Upcoming Release
21+
* Removed these aliases:
22+
* `Get-AzAks`
23+
* `New-AzAks`
24+
* `Set-AzAks`
25+
* `Remove-AzAks`
2126

2227
## Version 3.1.3
2328
* Updated the description of `Force` in `Invoke-AzAksRunCommand` [#17756]

src/Aks/Aks/Commands/GetAzureRmAks.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ namespace Microsoft.Azure.Commands.Aks
2929
{
3030
[GenericBreakingChange("Get-AzAks will be removed in the next major release. Please use Get-AzAksCluster instead of Get-AzAks")]
3131
[Cmdlet("Get", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "AksCluster", DefaultParameterSetName = ResourceGroupParameterSet)]
32-
[Alias("Get-" + ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "Aks")]
3332
[OutputType(typeof(PSKubernetesCluster))]
3433
public class GetAzureRmAks : KubeCmdletBase
3534
{

src/Aks/Aks/Commands/NewAzureRmAks.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ namespace Microsoft.Azure.Commands.Aks
4040
{
4141
[GenericBreakingChange("New-AzAks will be removed in the next major release. Please use New-AzAksCluster instead of New-AzAks")]
4242
[Cmdlet("New", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "AksCluster", DefaultParameterSetName = DefaultParamSet, SupportsShouldProcess = true)]
43-
[Alias("New-" + ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "Aks")]
4443
[OutputType(typeof(PSKubernetesCluster))]
4544
public class NewAzureRmAks : CreateOrUpdateKubeBase
4645
{

src/Aks/Aks/Commands/RemoveAzureRmAks.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ namespace Microsoft.Azure.Commands.Aks
2424
{
2525
[GenericBreakingChange("Remove-AzAks will be removed in the next major release. Please use Remove-AzAksCluster instead of Remove-AzAks")]
2626
[Cmdlet("Remove", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "AksCluster", SupportsShouldProcess = true, DefaultParameterSetName = GroupNameParameterSet)]
27-
[Alias("Remove-" + ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "Aks")]
2827
[OutputType(typeof(bool))]
2928
public class RemoveAzureRmAks : KubeCmdletBase
3029
{

src/Aks/Aks/Commands/SetAzureRmAks.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ namespace Microsoft.Azure.Commands.Aks
3838
{
3939
[GenericBreakingChange("Set-AzAks will be removed in the next major release. Please use Set-AzAksCluster instead of Set-AzAks")]
4040
[Cmdlet("Set", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "AksCluster", DefaultParameterSetName = DefaultParamSet, SupportsShouldProcess = true)]
41-
[Alias("Set-" + ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "Aks")]
4241
[OutputType(typeof(PSKubernetesCluster))]
4342
public class SetAzureRmAks : CreateOrUpdateKubeBase
4443
{

src/Aks/Aks/help/Az.Aks.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ Gets the details of the upgrade profile for a managed cluster with a specified r
3131

3232
### [Get-AzAksVersion](Get-AzAksVersion.md)
3333
List available version for creating managed Kubernetes cluster.
34+
The operation returns properties of each orchestrator including version, available upgrades and whether that version or upgrades are in preview.
3435

3536
### [Import-AzAksCredential](Import-AzAksCredential.md)
3637
Import and merge Kubectl config for a managed Kubernetes Cluster.
@@ -44,6 +45,10 @@ Run a shell command (with kubectl, helm) on your aks cluster, support attaching
4445
### [New-AzAksCluster](New-AzAksCluster.md)
4546
Create a new managed Kubernetes cluster.
4647

48+
The cmdlet may call below Microsoft Graph API according to input parameters:
49+
50+
- POST /servicePrincipals
51+
4752
### [New-AzAksNodePool](New-AzAksNodePool.md)
4853
Create a new node pool in specified cluster.
4954

src/Compute/Compute.Test/ScenarioTests/VirtualMachineTests.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -493,5 +493,12 @@ public void TestGetVirtualMachineById()
493493
{
494494
TestRunner.RunTestScript("Test-GetVirtualMachineById");
495495
}
496+
497+
[Fact]
498+
[Trait(Category.AcceptanceType, Category.CheckIn)]
499+
public void TestVirtualMachinePlatformFaultDomain()
500+
{
501+
TestRunner.RunTestScript("Test-VirtualMachinePlatformFaultDomain");
502+
}
496503
}
497504
}

src/Compute/Compute.Test/ScenarioTests/VirtualMachineTests.ps1

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5714,3 +5714,84 @@ function Test-GetVirtualMachineById
57145714
Clean-ResourceGroup $rgname;
57155715
}
57165716
}
5717+
5718+
<#
5719+
.SYNOPSIS
5720+
Test Test GetVirtualMachineById Parameter Set
5721+
#>
5722+
function Test-VirtualMachinePlatformFaultDomain
5723+
{
5724+
# Setup
5725+
$rgname = Get-ComputeTestResourceName;
5726+
$loc = Get-ComputeVMLocation;
5727+
5728+
try
5729+
{
5730+
New-AzResourceGroup -Name $rgname -Location $loc -Force;
5731+
5732+
# VM Profile & Hardware
5733+
$vmname = 'vm' + $rgname;
5734+
$domainNameLabel = "d1" + $rgname;
5735+
5736+
$vnetname = "myVnet";
5737+
$vnetAddress = "10.0.0.0/16";
5738+
$subnetname = "slb" + $rgname;
5739+
$subnetAddress = "10.0.2.0/24";
5740+
$vmssName = "vmss" + $rgname;
5741+
$FaultDomainNumber = 2;
5742+
$vmssFaultDomain = 3;
5743+
5744+
$OSDiskName = $vmname + "-osdisk";
5745+
$NICName = $vmname+ "-nic";
5746+
$NSGName = $vmname + "-NSG";
5747+
$OSDiskSizeinGB = 128;
5748+
$VMSize = "Standard_DS2_v2";
5749+
$PublisherName = "MicrosoftWindowsServer";
5750+
$Offer = "WindowsServer";
5751+
$SKU = "2019-Datacenter";
5752+
5753+
5754+
5755+
# Creating a VM using Simple parameterset
5756+
$securePassword = Get-PasswordForVM | ConvertTo-SecureString -AsPlainText -Force;
5757+
$user = "admin01";
5758+
$cred = New-Object System.Management.Automation.PSCredential ($user, $securePassword);
5759+
5760+
$frontendSubnet = New-AzVirtualNetworkSubnetConfig -Name $subnetname -AddressPrefix $subnetAddress;
5761+
5762+
$vnet = New-AzVirtualNetwork -Name $vnetname -ResourceGroupName $rgname -Location $loc -AddressPrefix $vnetAddress -Subnet $frontendSubnet;
5763+
5764+
$vmssConfig = New-AzVmssConfig -Location $loc -PlatformFaultDomainCount $vmssFaultDomain;
5765+
$VMSS = New-AzVmss -ResourceGroupName $RGName -Name $VMSSName -VirtualMachineScaleSet $vmssConfig -Verbose;
5766+
5767+
$nsgRuleRDP = New-AzNetworkSecurityRuleConfig -Name RDP -Protocol Tcp -Direction Inbound -Priority 1001 -SourceAddressPrefix * -SourcePortRange * -DestinationAddressPrefix * -DestinationPortRange 3389 -Access Allow;
5768+
$nsg = New-AzNetworkSecurityGroup -ResourceGroupName $RGName -Location $loc -Name $NSGName -SecurityRules $nsgRuleRDP;
5769+
$nic = New-AzNetworkInterface -Name $NICName -ResourceGroupName $RGName -Location $loc -SubnetId $vnet.Subnets[0].Id -NetworkSecurityGroupId $nsg.Id -EnableAcceleratedNetworking;
5770+
5771+
# VM
5772+
$vmConfig = New-AzVMConfig -VMName $vmName -VMSize $VMSize -VmssId $VMSS.Id -PlatformFaultDomain $FaultDomainNumber ;
5773+
Set-AzVMOperatingSystem -VM $vmConfig -Windows -ComputerName $vmName -Credential $cred ;
5774+
Set-AzVMOSDisk -VM $vmConfig -StorageAccountType "Premium_LRS" -Caching ReadWrite -Name $OSDiskName -DiskSizeInGB $OSDiskSizeinGB -CreateOption FromImage ;
5775+
Set-AzVMSourceImage -VM $vmConfig -PublisherName $PublisherName -Offer $Offer -Skus $SKU -Version latest ;
5776+
Add-AzVMNetworkInterface -VM $vmConfig -Id $nic.Id;
5777+
5778+
New-AzVM -ResourceGroupName $RGName -Location $loc -VM $vmConfig ;
5779+
$vm = Get-AzVm -ResourceGroupName $rgname -Name $vmName;
5780+
5781+
Assert-AreEqual $vm.PlatformFaultDomain $FaultDomainNumber;
5782+
5783+
# Create VM using Default Parameter set
5784+
$domainNameLabel = "d1" + $rgname;
5785+
$vmnameDef = "defvm" + $rgname;
5786+
$platformFaultDomainVMDefaultSet = 2;
5787+
$vmDef = New-AzVM -ResourceGroupName $rgname -Name $vmname -Credential $cred -DomainNameLabel $domainNameLabel -PlatformFaultDomain $platformFaultDomainVMDefaultSet -VmssId $VMSS.Id;
5788+
5789+
Assert-AreEqual $vmDef.PlatformFaultDomain $platformFaultDomainVMDefaultSet;
5790+
5791+
}
5792+
finally
5793+
{
5794+
# Cleanup
5795+
Clean-ResourceGroup $rgname;
5796+
}
5797+
}

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

Lines changed: 3528 additions & 0 deletions
Large diffs are not rendered by default.

src/Compute/Compute/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
2121
-->
2222
## Upcoming Release
23+
* Edited `New-AzVm` cmdlet internal logic to use the `PlatformFaultDomain` value in the `PSVirtualMachine` object passed to it in the new virtual machine.
2324

2425
## Version 4.26.0
2526
* Added `-ImageReferenceId` parameter to following cmdlets: `New-AzVm`, `New-AzVmConfig`, `New-AzVmss`, `Set-AzVmssStorageProfile`

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -821,7 +821,8 @@ public void DefaultExecuteCmdlet()
821821
BillingProfile = this.VM.BillingProfile,
822822
SecurityProfile = this.VM.SecurityProfile,
823823
CapacityReservation = this.VM.CapacityReservation,
824-
UserData = this.VM.UserData
824+
UserData = this.VM.UserData,
825+
PlatformFaultDomain = this.VM.PlatformFaultDomain
825826
};
826827

827828
Dictionary<string, List<string>> auxAuthHeader = null;

src/Compute/Compute/help/New-AzVM.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,23 @@ New-AzVm -ResourceGroupName ResourceGroup1 -Location SouthCentralUS -VM $Virtual
224224

225225
This example deploys a Windows VM from the marketplace in one resource group with an existing subnet in another resource group.
226226

227+
### Example 6: Creating a new VM as part of a VMSS with a PlatformFaultDomain value.
228+
```
229+
$resourceGroupName= <Resource Group Name>
230+
$domainNameLabel = <Domain Name Label Name>
231+
$vmname = "<Virtual Machine Name>
232+
$platformFaultDomainVMDefaultSet = 2
233+
$securePassword = <Password> | ConvertTo-SecureString -AsPlainText -Force
234+
$user = <Username>
235+
$cred = New-Object System.Management.Automation.PSCredential ($user, $securePassword)
236+
$vmssName = <Vmss Name>;
237+
238+
$vmssConfig = New-AzVmssConfig -Location $loc -PlatformFaultDomainCount $vmssFaultDomain;
239+
$vmss = New-AzVmss -ResourceGroupName $resourceGroupName -Name $vmssName -VirtualMachineScaleSet $vmssConfig;
240+
241+
$vm = New-AzVM -ResourceGroupName $resourceGroupName -Name $vmname -Credential $cred -DomainNameLabel $domainNameLabel -PlatformFaultDomain $platformFaultDomainVMDefaultSet -VmssId $vmss.Id
242+
```
243+
227244
## PARAMETERS
228245

229246
### -AddressPrefix

src/DataFactory/DataFactoryV2/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+
* Fixed Set-AzDataFactoryV2 -InputObject not correct with PublicNetworkAccess Parameter
2122

2223
## Version 1.16.6
2324
* Updated ADF .Net SDK version to 6.0.0

src/DataFactory/DataFactoryV2/DataFactories/SetAzureDataFactoryCommand.cs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ public override void ExecuteCmdlet()
501501
factoryIdentityType = this.IdentityType;
502502
}
503503

504-
if(this.UserAssignedIdentity != null && this.UserAssignedIdentity.Count > 0)
504+
if (this.UserAssignedIdentity != null && this.UserAssignedIdentity.Count > 0)
505505
{
506506
if (!factoryIdentityType.ToLower().Contains(FactoryIdentityType.UserAssigned.ToLower()))
507507
{
@@ -511,7 +511,7 @@ public override void ExecuteCmdlet()
511511
FactoryIdentity factoryIdentity = new FactoryIdentity(factoryIdentityType, userAssignedIdentities: this.UserAssignedIdentity);
512512

513513
EncryptionConfiguration encryption = null;
514-
if(!string.IsNullOrWhiteSpace(this.EncryptionVaultBaseUrl) && !string.IsNullOrWhiteSpace(this.EncryptionKeyName))
514+
if (!string.IsNullOrWhiteSpace(this.EncryptionVaultBaseUrl) && !string.IsNullOrWhiteSpace(this.EncryptionKeyName))
515515
{
516516
CMKIdentityDefinition cmkIdentity = null;
517517
if (!string.IsNullOrWhiteSpace(this.EncryptionUserAssignedIdentity))
@@ -552,14 +552,15 @@ private void ValidateParameters()
552552
this.ResourceGroupName = InputObject.ResourceGroupName;
553553
this.Name = InputObject.DataFactoryName;
554554
this.Location = this.Location ?? InputObject.Location;
555+
this.PublicNetworkAccess = this.PublicNetworkAccess ?? InputObject.PublicNetworkAccess;
555556
this.Tag = this.Tag ?? new Hashtable((IDictionary)InputObject.Tags);
556557

557-
if(InputObject.Identity != null)
558+
if (InputObject.Identity != null)
558559
{
559560
this.IdentityType = InputObject.Identity.Type;
560561
this.UserAssignedIdentity = InputObject.Identity.UserAssignedIdentities;
561562
}
562-
if(InputObject.Encryption != null)
563+
if (InputObject.Encryption != null)
563564
{
564565
this.EncryptionVaultBaseUrl = InputObject.Encryption.VaultBaseUrl;
565566
this.EncryptionKeyName = InputObject.Encryption.KeyName;
@@ -590,7 +591,7 @@ private void ValidateParameters()
590591
}
591592
}
592593
}
593-
594+
594595
this.GlobalParameterDefinition = InputObject.GlobalParameters;
595596
}
596597

src/ManagedServiceIdentity/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+
* General availability of `Az.ManagedServiceIdentity`
2122

2223
## Version 0.8.0
2324
* Bumped API Version to 2018-11-30

src/Resources/Resources/help/Get-AzManagementGroupDeployment.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ This command gets all deployments at the management group "myMG".
4040

4141
### Example 2: Get a deployment by name
4242
```powershell
43-
Get-AzDeployment -ManagementGroupId "myMG" -Name "Deploy01"
43+
Get-AzManagementGroupDeployment -ManagementGroupId "myMG" -Name "Deploy01"
4444
```
4545

4646
This command gets the "Deploy01" deployment at the management group "myMG".

src/Resources/Resources/help/Get-AzPolicyDefinition.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ This command gets all built-in policy definitions from the subscription with ID
8484

8585
### Example 5: Get policy definitions from a given category
8686
```powershell
87-
Get-AzPolicyDefinition | where-object {$_.Properties.metadata.category -eq "Virtual Machine"}
87+
Get-AzPolicyDefinition | Where-Object {$_.Properties.metadata.category -eq "Virtual Machine"}
8888
```
8989

9090
This command gets all policy definitions in category "Virtual Machine".

src/Resources/Resources/help/Get-AzPolicySetDefinition.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ This command gets all custom policy set definitions from the management group na
8383

8484
### Example 5: Get policy set definitions from a given category
8585
```powershell
86-
Get-AzPolicySetDefinition | where-object {$_.Properties.metadata.category -eq "Virtual Machine"}
86+
Get-AzPolicySetDefinition | Where-Object {$_.Properties.metadata.category -eq "Virtual Machine"}
8787
```
8888

8989
This command gets all policy set definitions in category "Virtual Machine".

src/Resources/Resources/help/Get-AzResource.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ The **Get-AzResource** cmdlet gets Azure resources.
4343
### Example 1: Get all resources in the current subscription
4444

4545
```powershell
46-
Get-AzResource | ft
46+
Get-AzResource | Format-Table
4747
```
4848

4949
```output
@@ -65,7 +65,7 @@ This command gets all of the resources in the current subscription.
6565
### Example 2: Get all resources in a resource group
6666

6767
```powershell
68-
Get-AzResource -ResourceGroupName testRG | ft
68+
Get-AzResource -ResourceGroupName testRG | Format-Table
6969
```
7070

7171
```output
@@ -84,7 +84,7 @@ This command gets all of the resources in the resource group "testRG".
8484
### Example 3: Get all resources whose resource group matches the provided wildcard
8585

8686
```powershell
87-
Get-AzResource -ResourceGroupName other* | ft
87+
Get-AzResource -ResourceGroupName other* | Format-Table
8888
```
8989

9090
```output
@@ -100,7 +100,7 @@ This command gets all of the resources whose resource group they belong in being
100100
### Example 4: Get all resources with a given name
101101

102102
```powershell
103-
Get-AzResource -Name testVM | fl
103+
Get-AzResource -Name testVM | Format-List
104104
```
105105

106106
```output
@@ -122,7 +122,7 @@ This command gets all of the resources whose resource name is "testVM".
122122
### Example 5: Get all resources whose name matches the provided wildcard
123123

124124
```powershell
125-
Get-AzResource -Name test* | ft
125+
Get-AzResource -Name test* | Format-Table
126126
```
127127

128128
```output
@@ -138,7 +138,7 @@ This command gets all of the resources whose resource name begins with "test".
138138
### Example 6: Get all resources of a given resource type
139139

140140
```powershell
141-
Get-AzResource -ResourceType Microsoft.Compute/virtualMachines | ft
141+
Get-AzResource -ResourceType Microsoft.Compute/virtualMachines | Format-Table
142142
```
143143

144144
```output

0 commit comments

Comments
 (0)