Skip to content

Commit 2bd1e22

Browse files
committed
update scoped deployments
1 parent 42da1de commit 2bd1e22

File tree

2 files changed

+19
-9
lines changed

2 files changed

+19
-9
lines changed

articles/azure-resource-manager/templates/deploy-to-management-group.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Deploy resources to management group
33
description: Describes how to deploy resources at the management group scope in an Azure Resource Manager template.
44
ms.topic: conceptual
5-
ms.date: 02/10/2020
5+
ms.date: 03/02/2020
66
---
77

88
# Create resources at the management group level
@@ -40,7 +40,16 @@ https://schema.management.azure.com/schemas/2019-08-01/managementGroupDeployment
4040

4141
## Deployment commands
4242

43-
The command for management group deployments is different than the command for resource group deployments.
43+
The commands for management group deployments are different than the commands for resource group deployments.
44+
45+
For Azure PowerShell, use [New-AzManagementGroupDeployment](/powershell/module/az.resources/new-azmanagementgroupdeployment).
46+
47+
```azurepowershell-interactive
48+
New-AzManagementGroupDeployment `
49+
-ManagementGroupId "myMG" `
50+
-Location "West US" `
51+
-TemplateUri https://raw.githubusercontent.com/Azure/azure-docs-json-samples/master/management-level-deployment/azuredeploy.json
52+
```
4453

4554
For REST API, use [Deployments - Create At Management Group Scope](/rest/api/resources/deployments/createorupdateatmanagementgroupscope).
4655

articles/azure-resource-manager/templates/deploy-to-subscription.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Deploy resources to subscription
33
description: Describes how to create a resource group in an Azure Resource Manager template. It also shows how to deploy resources at the Azure subscription scope.
44
ms.topic: conceptual
5-
ms.date: 02/10/2020
5+
ms.date: 03/02/2020
66
---
77

88
# Create resource groups and resources at the subscription level
@@ -15,6 +15,7 @@ To deploy templates at the subscription level, use Azure CLI, PowerShell, or RES
1515

1616
You can deploy the following resource types at the subscription level:
1717

18+
* [budgets](/azure/templates/microsoft.consumption/budgets)
1819
* [deployments](/azure/templates/microsoft.resources/deployments)
1920
* [peerAsns](/azure/templates/microsoft.peering/peerasns)
2021
* [policyAssignments](/azure/templates/microsoft.authorization/policyassignments)
@@ -55,10 +56,10 @@ az deployment create \
5556
```
5657

5758

58-
For the PowerShell deployment command, use [New-AzDeployment](/powershell/module/az.resources/new-azdeployment). The following example deploys a template to create a resource group:
59+
For the PowerShell deployment command, use [New-AzDeployment](/powershell/module/az.resources/new-azdeployment) or **New-AzSubscriptionDeployment**. The following example deploys a template to create a resource group:
5960

6061
```azurepowershell-interactive
61-
New-AzDeployment `
62+
New-AzSubscriptionDeployment `
6263
-Name demoDeployment `
6364
-Location centralus `
6465
-TemplateUri https://raw.githubusercontent.com/Azure/azure-docs-json-samples/master/azure-resource-manager/emptyRG.json `
@@ -295,7 +296,7 @@ $definition = Get-AzPolicyDefinition | Where-Object { $_.Properties.DisplayName
295296
$locations = @("westus", "westus2")
296297
$policyParams =@{listOfAllowedLocations = @{ value = $locations}}
297298
298-
New-AzDeployment `
299+
New-AzSubscriptionDeployment `
299300
-Name policyassign `
300301
-Location centralus `
301302
-TemplateUri https://raw.githubusercontent.com/Azure/azure-docs-json-samples/master/azure-resource-manager/policyassign.json `
@@ -361,16 +362,16 @@ az deployment create \
361362
To deploy this template with PowerShell, use:
362363

363364
```azurepowershell
364-
New-AzDeployment `
365+
New-AzSubscriptionDeployment `
365366
-Name definePolicy `
366367
-Location centralus `
367368
-TemplateUri https://raw.githubusercontent.com/Azure/azure-docs-json-samples/master/azure-resource-manager/policydefineandassign.json
368369
```
369370

370371
## Template samples
371372

372-
* Create a resource group, lock it and give permissions to it. See [here](https://github.com/Azure/azure-quickstart-templates/tree/master/subscription-level-deployments/create-rg-lock-role-assignment).
373-
* Create a resource group, a policy and a policy assignment. See [here](https://github.com/Azure/azure-docs-json-samples/blob/master/subscription-level-deployment/azuredeploy.json).
373+
* [Create a resource group, lock it and give permissions to it](https://github.com/Azure/azure-quickstart-templates/tree/master/subscription-level-deployments/create-rg-lock-role-assignment).
374+
* [Create a resource group, a policy, and a policy assignment](https://github.com/Azure/azure-docs-json-samples/blob/master/subscription-level-deployment/azuredeploy.json).
374375

375376
## Next steps
376377

0 commit comments

Comments
 (0)