Skip to content

Commit 4d2fec5

Browse files
Merge pull request #110734 from mumian/0408-tutorial-copy
update the copy tutorial
2 parents b160a98 + df11729 commit 4d2fec5

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed
Loading

articles/azure-resource-manager/templates/template-tutorial-create-multiple-instances.md

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Create multiple resource instances
33
description: Learn how to create an Azure Resource Manager template to create multiple Azure resource instances.
44
author: mumian
5-
ms.date: 03/04/2019
5+
ms.date: 04/08/2020
66
ms.topic: tutorial
77
ms.author: jgao
88
---
@@ -59,7 +59,7 @@ The completed template looks like:
5959
6060
```json
6161
{
62-
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
62+
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
6363
"contentVersion": "1.0.0.0",
6464
"parameters": {
6565
"storageAccountType": {
@@ -86,18 +86,18 @@ The completed template looks like:
8686
"resources": [
8787
{
8888
"type": "Microsoft.Storage/storageAccounts",
89+
"apiVersion": "2019-04-01",
8990
"name": "[concat(copyIndex(),'storage', uniqueString(resourceGroup().id))]",
90-
"apiVersion": "2018-02-01",
9191
"location": "[parameters('location')]",
9292
"sku": {
9393
"name": "[parameters('storageAccountType')]"
9494
},
95-
"kind": "Storage",
96-
"properties": {},
95+
"kind": "StorageV2",
9796
"copy": {
9897
"name": "storagecopy",
9998
"count": 3
100-
}
99+
},
100+
"properties": {}
101101
}
102102
]
103103
}
@@ -114,16 +114,19 @@ Refer to the [Deploy the template](quickstart-create-templates-use-visual-studio
114114
To list all three storage accounts, omit the --name parameter:
115115
116116
# [Azure CLI](#tab/azure-cli)
117+
117118
```azurecli
118-
echo "Enter the Resource Group name:" &&
119-
read resourceGroupName &&
119+
echo "Enter a project name that is used to generate resource group name:" &&
120+
read projectName &&
121+
resourceGroupName="${projectName}rg" &&
120122
az storage account list --resource-group $resourceGroupName
121123
```
122124
123125
# [PowerShell](#tab/azure-powershell)
124126
125127
```azurepowershell
126-
$resourceGroupName = Read-Host -Prompt "Enter the resource group name"
128+
$projectName = Read-Host -Prompt "Enter a project name that is used to generate resource group name"
129+
$resourceGroupName = "${projectName}rg"
127130
Get-AzStorageAccount -ResourceGroupName $resourceGroupName
128131
```
129132

0 commit comments

Comments
 (0)