Skip to content

Commit 0f43af2

Browse files
authored
Update capacity-reservation-create.md
1 parent c90b5a2 commit 0f43af2

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

articles/virtual-machines/capacity-reservation-create.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,19 +59,17 @@ Before creating capacity reservation, VM sizes available for reservation can be
5959

6060
Before you create a capacity reservation, you can check the reservation available VM sizes for the region selected. The following example lists the capacity reservation available VM sizes in East US location using Azure CLI:
6161

62-
```azurecli-interactive
62+
```azurecli-interactive
6363
az vm list-skus -l eastus --resource-type virtualMachines --query "[?contains(capabilities[?name == 'CapacityReservationSupported' && value == 'True'].name,'CapacityReservationSupported')].name"
64-
```
64+
```
6565
### [PowerShell](#tab/powershell1)
6666

6767
Before you create a capacity reservation, you can check the reservation available VM sizes for the region selected using Get-AzComputeResourceSku for Capability property for Resource type Virtual Machines. The following example lists the capacity reservation available VM sizes in East US location:
6868

69-
70-
71-
```powershell-interactive
69+
```powershell-interactive
7270
$vmsizes = Get-AzComputeResourceSku -Location eastus | where {$_.ResourceType -eq "virtualMachines"}
7371
foreach($vmsize in $vmsizes) { foreach($capability in $vmsize.capabilities) { if($capability.Name -eq 'CapacityReservationSupported' -and $capability.Value -eq 'true'){ $vmsize.name } } }
74-
```
72+
```
7573
---
7674
<!-- The three dashes above show that your section of tabbed content is complete. Do not remove them :) -->
7775

0 commit comments

Comments
 (0)