Skip to content

Commit e680993

Browse files
committed
AVD create application group update PowerShell and CLI parameteers
1 parent b662224 commit e680993

File tree

1 file changed

+65
-7
lines changed

1 file changed

+65
-7
lines changed

articles/virtual-desktop/create-application-group-workspace.md

Lines changed: 65 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Learn how to create an application group and a workspace, and assig
44
ms.topic: how-to
55
author: dknappettmsft
66
ms.author: daknappe
7-
ms.date: 03/01/2023
7+
ms.date: 03/22/2023
88
---
99

1010
# Create an application group, a workspace, and assign users in Azure Virtual Desktop
@@ -79,13 +79,41 @@ Here's how to create an application group using the [desktopvirtualization](/cli
7979
8080
[!INCLUDE [include-cloud-shell-local-cli](includes/include-cloud-shell-local-cli.md)]
8181

82-
2. Use the `az desktopvirtualization applicationgroup create` command with the following example to create an application group. More parameters are available, such as to register existing application groups. For more information, see the [az desktopvirtualization applicationgroup Azure CLI reference](/cli/azure/desktopvirtualization/applicationgroup).
82+
2. Get the resource ID of the host pool you want to create an application group for and store it in a variable by running the following command:
8383

8484
```azurecli
85-
az desktopvirtualization applicationgroup create --name <Name> --resource-group <ResourceGroupName>
85+
hostPoolArmPath=$(az desktopvirtualization hostpool show \
86+
--name <Name> \
87+
--resource-group <ResourceGroupName> \
88+
--query [id] \
89+
--output tsv)
8690
```
8791

88-
3. You can view the properties of your new application group by running the following command:
92+
3. Use the `az desktopvirtualization applicationgroup create` command with the following examples to create an application group. For more information, see the [az desktopvirtualization applicationgroup Azure CLI reference](/cli/azure/desktopvirtualization/applicationgroup).
93+
94+
1. To create a Desktop application group in the Azure region UK South, run the following command:
95+
96+
```azurecli
97+
az desktopvirtualization applicationgroup create \
98+
--name <Name> \
99+
--resource-group <ResourceGroupName> \
100+
--application-group-type Desktop \
101+
--host-pool-arm-path $hostPoolArmPath \
102+
--location uksouth
103+
```
104+
105+
1. To create a RemoteApp application group in the Azure region UK South, run the following command. You can only create a RemoteApp application group with a pooled host pool.
106+
107+
```azurecli
108+
az desktopvirtualization applicationgroup create \
109+
--name <Name> \
110+
--resource-group <ResourceGroupName> \
111+
--application-group-type RemoteApp \
112+
--host-pool-arm-path $hostPoolArmPath \
113+
--location uksouth
114+
```
115+
116+
4. You can view the properties of your new application group by running the following command:
89117
90118
```azurecli
91119
az desktopvirtualization applicationgroup show --name <Name> --resource-group <ResourceGroupName>
@@ -100,13 +128,43 @@ Here's how to create an application group using the [Az.DesktopVirtualization](/
100128
101129
[!INCLUDE [include-cloud-shell-local-powershell](includes/include-cloud-shell-local-powershell.md)]
102130

103-
2. Use the `New-AzWvdApplicationGroup` cmdlet with the following example to create an application group. More parameters are available, such as to register existing application groups. For more information, see the [New-AzWvdApplicationGroup PowerShell reference](/powershell/module/az.desktopvirtualization/new-azwvdapplicationgroup).
131+
2. Get the resource ID of the host pool you want to create an application group for and store it in a variable by running the following command:
104132

105133
```azurepowershell
106-
New-AzWvdApplicationGroup -Name <Name> -ResourceGroupName <ResourceGroupName>
134+
$hostPoolArmPath = (Get-AzWvdHostPool -Name <HostPoolName> -ResourceGroupName <ResourceGroupName).Id
107135
```
108136

109-
3. You can view the properties of your new workspace by running the following command:
137+
3. Use the `New-AzWvdApplicationGroup` cmdlet with the following examples to create an application group. For more information, see the [New-AzWvdApplicationGroup PowerShell reference](/powershell/module/az.desktopvirtualization/new-azwvdapplicationgroup).
138+
139+
1. To create a Desktop application group in the Azure region UK South, run the following command:
140+
141+
```azurepowershell
142+
$parameters = @{
143+
Name = '<Name>'
144+
ResourceGroupName = '<ResourceGroupName>'
145+
ApplicationGroupType = 'Desktop'
146+
HostPoolArmPath = $hostPoolArmPath
147+
Location = 'uksouth'
148+
}
149+
150+
New-AzWvdApplicationGroup @parameters
151+
```
152+
153+
1. To create a RemoteApp application group in the Azure region UK South, run the following command. You can only create a RemoteApp application group with a pooled host pool.
154+
155+
```azurepowershell
156+
$parameters = @{
157+
Name = '<Name>'
158+
ResourceGroupName = '<ResourceGroupName>'
159+
ApplicationGroupType = 'RemoteApp'
160+
HostPoolArmPath = $hostPoolArmPath
161+
Location = 'uksouth'
162+
}
163+
164+
New-AzWvdApplicationGroup @parameters
165+
```
166+
167+
4. You can view the properties of your new workspace by running the following command:
110168
111169
```azurepowershell
112170
Get-AzWvdApplicationGroup -Name <Name> -ResourceGroupName <ResourceGroupName> | FL *

0 commit comments

Comments
 (0)