Skip to content

Commit af7af20

Browse files
author
Cynthia Nottingham
committed
2 parents 1bc28ae + 4730b28 commit af7af20

File tree

111 files changed

+766
-633
lines changed

Some content is hidden

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

111 files changed

+766
-633
lines changed

.openpublishing.redirection.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6706,6 +6706,10 @@
67066706
"redirect_url": "/azure/logic-apps/logic-apps-using-sap-connector",
67076707
"redirect_document_id": true
67086708
},
6709+
{
6710+
"source_path": "articles/scheduler/get-started-portal.md",
6711+
"redirect_url": "/azure/scheduler/migrate-from-scheduler-to-logic-apps",
6712+
},
67096713
{
67106714
"source_path": "articles/connectors/connectors-create-api-googledrive.md",
67116715
"redirect_url": "https://docs.microsoft.com/connectors/googledrive/",

articles/app-service/app-service-web-tutorial-dotnetcore-sqldb.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ What you learn how to:
3636
To complete this tutorial:
3737

3838
* [Install Git](https://git-scm.com/)
39-
* [Install .NET Core](https://www.microsoft.com/net/core/)
39+
* [Install .NET Core SDK](https://dotnet.microsoft.com/download)
4040

4141
## Create local .NET Core app
4242

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

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,24 @@
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: 03/02/2020
5+
ms.date: 03/06/2020
66
---
77

88
# Create resources at the management group level
99

10-
Typically, you deploy Azure resources to a resource group in your Azure subscription. However, you can also create resources at the management group level. You use management group level deployments to take actions that make sense at that level, such as assigning [role-based access control](../../role-based-access-control/overview.md) or applying [policies](../../governance/policy/overview.md).
10+
Typically, you deploy Azure resources to a resource group in your Azure subscription. However, you can also create resources at the:
11+
12+
* [subscription level](deploy-to-subscription.md)
13+
* management group level (covered in this article)
14+
* [tenant level](deploy-to-tenant.md)
15+
16+
You use management group level deployments to take actions that make sense at that level, such as assigning [role-based access control](../../role-based-access-control/overview.md) or applying [policies](../../governance/policy/overview.md).
1117

1218
## Supported resources
1319

1420
You can deploy the following resource types at the management group level:
1521

16-
* [deployments](/azure/templates/microsoft.resources/deployments)
22+
* [deployments](/azure/templates/microsoft.resources/deployments) - for nested templates that deploy to subscriptions or resource groups.
1723
* [policyAssignments](/azure/templates/microsoft.authorization/policyassignments)
1824
* [policyDefinitions](/azure/templates/microsoft.authorization/policydefinitions)
1925
* [policySetDefinitions](/azure/templates/microsoft.authorization/policysetdefinitions)

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

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,18 @@
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: 03/02/2020
5+
ms.date: 03/06/2020
66
---
77

88
# Create resource groups and resources at the subscription level
99

10-
Typically, you deploy Azure resources to a resource group in your Azure subscription. However, you can also create resources at the subscription level. You use subscription level deployments to take actions that make sense at that level, such as creating resource groups, or assigning [role-based access control](../../role-based-access-control/overview.md).
10+
Typically, you deploy Azure resources to a resource group in your Azure subscription. However, you can also create resources at the:
11+
12+
* subscription level (covered in this article)
13+
* [management group level](deploy-to-management-group.md)
14+
* [tenant level](deploy-to-tenant.md)
15+
16+
You use subscription level deployments to take actions that make sense at that level, such as creating resource groups, or assigning [role-based access control](../../role-based-access-control/overview.md).
1117

1218
To deploy templates at the subscription level, use Azure CLI, PowerShell, or REST API. The Azure portal doesn't support deployment in the subscription level.
1319

@@ -16,7 +22,7 @@ To deploy templates at the subscription level, use Azure CLI, PowerShell, or RES
1622
You can deploy the following resource types at the subscription level:
1723

1824
* [budgets](/azure/templates/microsoft.consumption/budgets)
19-
* [deployments](/azure/templates/microsoft.resources/deployments)
25+
* [deployments](/azure/templates/microsoft.resources/deployments) - for nested templates that deploy to resource groups.
2026
* [peerAsns](/azure/templates/microsoft.peering/peerasns)
2127
* [policyAssignments](/azure/templates/microsoft.authorization/policyassignments)
2228
* [policyDefinitions](/azure/templates/microsoft.authorization/policydefinitions)
@@ -83,12 +89,12 @@ For subscription-level deployments, there are some important considerations when
8389

8490
* The [resourceGroup()](template-functions-resource.md#resourcegroup) function is **not** supported.
8591
* The [reference()](template-functions-resource.md#reference) and [list()](template-functions-resource.md#list) functions are supported.
86-
* The [resourceId()](template-functions-resource.md#resourceid) function is supported. Use it to get the resource ID for resources that are used at subscription level deployments. Don't provide a value for the resource group parameter.
92+
* Use the [subscriptionResourceId()](template-functions-resource.md#subscriptionresourceid) function to get the resource ID for resources that are deployed at subscription level.
8793

8894
For example, to get the resource ID for a policy definition, use:
8995

9096
```json
91-
resourceId('Microsoft.Authorization/roleDefinitions/', parameters('roleDefinition'))
97+
subscriptionResourceId('Microsoft.Authorization/roleDefinitions/', parameters('roleDefinition'))
9298
```
9399

94100
The returned resource ID has the following format:
@@ -97,8 +103,6 @@ For subscription-level deployments, there are some important considerations when
97103
/subscriptions/{subscriptionId}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
98104
```
99105

100-
Or, use the [subscriptionResourceId()](template-functions-resource.md#subscriptionresourceid) function to get the resource ID for a subscription level resource.
101-
102106
## Create resource groups
103107

104108
To create a resource group in an Azure Resource Manager template, define a [Microsoft.Resources/resourceGroups](/azure/templates/microsoft.resources/allversions) resource with a name and location for the resource group. You can create a resource group and deploy resources to that resource group in the same template.
Lines changed: 180 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,180 @@
1+
---
2+
title: Deploy resources to tenant
3+
description: Describes how to deploy resources at the tenant scope in an Azure Resource Manager template.
4+
ms.topic: conceptual
5+
ms.date: 03/06/2020
6+
---
7+
8+
# Create resources at the tenant level
9+
10+
Typically, you deploy Azure resources to a resource group in your Azure subscription. However, you can also create resources at the:
11+
12+
* [subscription level](deploy-to-subscription.md)
13+
* [management group level](deploy-to-management-group.md)
14+
* tenant level (covered in this article)
15+
16+
You use tenant level deployments to take actions that make sense at that level, such as assigning [role-based access control](../../role-based-access-control/overview.md) or applying [policies](../../governance/policy/overview.md).
17+
18+
## Supported resources
19+
20+
You can deploy the following resource types at the tenant level:
21+
22+
* [deployments](/azure/templates/microsoft.resources/deployments) - for nested templates that deploy to management groups or subscriptions.
23+
* [policyAssignments](/azure/templates/microsoft.authorization/policyassignments)
24+
* [policyDefinitions](/azure/templates/microsoft.authorization/policydefinitions)
25+
* [policySetDefinitions](/azure/templates/microsoft.authorization/policysetdefinitions)
26+
* [roleAssignments](/azure/templates/microsoft.authorization/roleassignments)
27+
* [roleDefinitions](/azure/templates/microsoft.authorization/roledefinitions)
28+
29+
### Schema
30+
31+
The schema you use for tenant deployments is different than the schema for resource group deployments.
32+
33+
For templates, use:
34+
35+
```json
36+
https://schema.management.azure.com/schemas/2019-08-01/tenantDeploymentTemplate.json#
37+
```
38+
39+
For parameter files, use:
40+
41+
```json
42+
https://schema.management.azure.com/schemas/2019-08-01/tenantDeploymentParameters.json#
43+
```
44+
45+
## Required access
46+
47+
The principal deploying the template must have permissions to create resources at the tenant scope. The principal must have permission to execute the deployment actions (`Microsoft.Resources/deployments/*`) and to create the resources defined in the template. For example, to create a management group, the principal must have Contributor permission at the tenant scope. To create role assignments, the principal must have Owner permission.
48+
49+
The Global Administrator for the Azure Active Directory doesn't automatically have permission to assign roles. To enable template deployments at the tenant scope, the Global Administrator must do the following steps:
50+
51+
1. Elevate account access so the Global Administrator can assign roles. For more information, see [Elevate access to manage all Azure subscriptions and management Groups](../../role-based-access-control/elevate-access-global-admin.md).
52+
53+
1. Assign Owner or Contributor to the principal that needs to deploy the templates.
54+
55+
```azurepowershell-interactive
56+
New-AzRoleAssignment -SignInName "[userId]" -Scope "/" -RoleDefinitionName "Owner"
57+
```
58+
59+
```azurecli-interactive
60+
az role assignment create --assignee "[userId]" --scope "/" --role "Owner"
61+
```
62+
63+
The principal now has the required permissions to deploy the template.
64+
65+
## Deployment commands
66+
67+
The commands for tenant deployments are different than the commands for resource group deployments.
68+
69+
For Azure PowerShell, use [New-AzTenantDeployment](/powershell/module/az.resources/new-aztenantdeployment).
70+
71+
```azurepowershell-interactive
72+
New-AzTenantDeployment `
73+
-Location "West US" `
74+
-TemplateUri https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/tenant-level-deployments/new-mg/azuredeploy.json
75+
```
76+
77+
For REST API, use [Deployments - Create Or Update At Tenant Scope](/rest/api/resources/deployments/createorupdateattenantscope).
78+
79+
## Deployment location and name
80+
81+
For tenant level deployments, you must provide a location for the deployment. The location of the deployment is separate from the location of the resources you deploy. The deployment location specifies where to store deployment data.
82+
83+
You can provide a name for the deployment, or use the default deployment name. The default name is the name of the template file. For example, deploying a template named **azuredeploy.json** creates a default deployment name of **azuredeploy**.
84+
85+
For each deployment name, the location is immutable. You can't create a deployment in one location when there's an existing deployment with the same name in a different location. If you get the error code `InvalidDeploymentLocation`, either use a different name or the same location as the previous deployment for that name.
86+
87+
## Use template functions
88+
89+
For tenant deployments, there are some important considerations when using template functions:
90+
91+
* The [resourceGroup()](template-functions-resource.md#resourcegroup) function is **not** supported.
92+
* The [subscription()](template-functions-resource.md#subscription) function is **not** supported.
93+
* The [reference()](template-functions-resource.md#reference) and [list()](template-functions-resource.md#list) functions are supported.
94+
* Use the [tenantResourceId()](template-functions-resource.md#tenantresourceid) function to get the resource ID for resources that are deployed at tenant level.
95+
96+
For example, to get the resource ID for a policy definition, use:
97+
98+
```json
99+
tenantResourceId('Microsoft.Authorization/policyDefinitions/', parameters('policyDefinition'))
100+
```
101+
102+
The returned resource ID has the following format:
103+
104+
```json
105+
/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
106+
```
107+
108+
## Create management group
109+
110+
The [following template](https://github.com/Azure/azure-quickstart-templates/tree/master/tenant-level-deployments/new-mg) creates a management group.
111+
112+
```json
113+
{
114+
"$schema": "https://schema.management.azure.com/schemas/2019-08-01/tenantDeploymentTemplate.json#",
115+
"contentVersion": "1.0.0.0",
116+
"parameters": {
117+
"mgName": {
118+
"type": "string",
119+
"defaultValue": "[concat('mg-', uniqueString(newGuid()))]"
120+
}
121+
},
122+
"resources": [
123+
{
124+
"type": "Microsoft.Management/managementGroups",
125+
"apiVersion": "2019-11-01",
126+
"name": "[parameters('mgName')]",
127+
"properties": {
128+
}
129+
}
130+
]
131+
}
132+
```
133+
134+
## Assign role
135+
136+
The [following template](https://github.com/Azure/azure-quickstart-templates/tree/master/tenant-level-deployments/tenant-role-assignment) assigns a role at the tenant scope.
137+
138+
```json
139+
{
140+
"$schema": "https://schema.management.azure.com/schemas/2019-08-01/tenantDeploymentTemplate.json#",
141+
"contentVersion": "1.0.0.0",
142+
"parameters": {
143+
"principalId": {
144+
"type": "string",
145+
"metadata": {
146+
"description": "principalId if the user that will be given contributor access to the resourceGroup"
147+
}
148+
},
149+
"roleDefinitionId": {
150+
"type": "string",
151+
"defaultValue": "8e3af657-a8ff-443c-a75c-2fe8c4bcb635",
152+
"metadata": {
153+
"description": "roleDefinition for the assignment - default is owner"
154+
}
155+
}
156+
},
157+
"variables": {
158+
// This creates an idempotent guid for the role assignment
159+
"roleAssignmentName": "[guid('/', parameters('principalId'), parameters('roleDefinitionId'))]"
160+
},
161+
"resources": [
162+
{
163+
"name": "[variables('roleAssignmentName')]",
164+
"type": "Microsoft.Authorization/roleAssignments",
165+
"apiVersion": "2019-04-01-preview",
166+
"properties": {
167+
"roleDefinitionId": "[tenantResourceId('Microsoft.Authorization/roleDefinitions', parameters('roleDefinitionId'))]",
168+
"principalId": "[parameters('principalId')]",
169+
"scope": "/"
170+
}
171+
}
172+
]
173+
}
174+
```
175+
176+
## Next steps
177+
178+
* To learn about assigning roles, see [Manage access to Azure resources using RBAC and Azure Resource Manager templates](../../role-based-access-control/role-assignments-template.md).
179+
* To learn about creating Azure Resource Manager templates, see [Authoring templates](template-syntax.md).
180+
* For a list of the available functions in a template, see [Template functions](template-functions.md).

articles/azure-resource-manager/templates/toc.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,6 @@
145145
- name: Outputs
146146
displayName: iteration,copy
147147
href: copy-outputs.md
148-
- name: Subscription level resources
149-
href: deploy-to-subscription.md
150-
- name: Management group level resources
151-
href: deploy-to-management-group.md
152148
- name: Use authoring tools
153149
items:
154150
- name: VS Code
@@ -182,7 +178,15 @@
182178
href: rollback-on-error.md
183179
- name: Secure template with SAS token
184180
href: secure-template-with-sas-token.md
185-
- name: Deploy to multiple resource groups or subscriptions
181+
- name: Scoped deployments
182+
items:
183+
- name: Subscription
184+
href: deploy-to-subscription.md
185+
- name: Management group
186+
href: deploy-to-management-group.md
187+
- name: Tenant
188+
href: deploy-to-tenant.md
189+
- name: Multiple resource groups or subscriptions
186190
href: cross-resource-group-deployment.md
187191
- name: Provide parameters
188192
items:

articles/cognitive-services/Bing-Web-Search/includes/quickstarts/web-search-client-library-csharp.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ Here are a few things that you'll need before running this quickstart:
2323
* [NuGet Package Manager](https://github.com/jmrog/vscode-nuget-package-manager)
2424
* [.NET Core SDK](https://www.microsoft.com/net/download)
2525

26-
[!INCLUDE [bing-web-search-quickstart-signup](../../../../../includes/bing-web-search-quickstart-signup.md)]
26+
[!INCLUDE [bing-web-search-quickstart-signup](~/includes/bing-web-search-quickstart-signup.md)]
2727

2828
## Create a project and install dependencies
2929

articles/cognitive-services/Bing-Web-Search/includes/quickstarts/web-search-client-library-java.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Here are a few things that you'll need before running this quickstart:
2222
* [Apache Maven](https://maven.apache.org/download.cgi) or your favorite build automation tool
2323
* A subscription key
2424

25-
[!INCLUDE [bing-web-search-quickstart-signup](../../../../../includes/bing-web-search-quickstart-signup.md)]
25+
[!INCLUDE [bing-web-search-quickstart-signup](~/includes/bing-web-search-quickstart-signup.md)]
2626

2727
## Create a project and set up your POM file
2828

articles/cognitive-services/Bing-Web-Search/includes/quickstarts/web-search-client-library-javascript.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Here are a few things that you'll need before running this quickstart:
2020
* [Node.js 6](https://nodejs.org/en/download/) or later
2121
* A subscription key
2222

23-
[!INCLUDE [bing-web-search-quickstart-signup](../../../../../includes/bing-web-search-quickstart-signup.md)]
23+
[!INCLUDE [bing-web-search-quickstart-signup](~/includes/bing-web-search-quickstart-signup.md)]
2424

2525

2626
## Set up your development environment

articles/cognitive-services/Bing-Web-Search/includes/quickstarts/web-search-client-library-python.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ The Bing Web Search SDK is compatible with Python 2.7, 3.3, 3.4, 3.5, and 3.6. W
2222
* [virtualenv](https://docs.python.org/3/tutorial/venv.html) for Python 2.7
2323
* [venv](https://pypi.python.org/pypi/virtualenv) for Python 3.x
2424

25-
[!INCLUDE [bing-web-search-quickstart-signup](../../../../../includes/bing-web-search-quickstart-signup.md)]
25+
[!INCLUDE [bing-web-search-quickstart-signup](~/includes/bing-web-search-quickstart-signup.md)]
2626

2727
## Create and configure your virtual environment
2828

0 commit comments

Comments
 (0)