Skip to content

Commit f800023

Browse files
committed
fixes MicrosoftDocs/azure-docs#8967
1 parent 973ff92 commit f800023

File tree

1 file changed

+16
-5
lines changed

1 file changed

+16
-5
lines changed

articles/azure-resource-manager/resource-manager-vscode-extension.md

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ms.service: azure-resource-manager
1111
ms.workload: multiple
1212
ms.tgt_pltfrm: na
1313
ms.devlang: na
14-
ms.date: 09/06/2017
14+
ms.date: 05/22/2018
1515
ms.topic: quickstart
1616
ms.author: tomfitz
1717
---
@@ -167,7 +167,18 @@ This article builds on the template you created in [Create and deploy your first
167167

168168
![Show variables](./media/resource-manager-vscode-extension/show-variables.png)
169169

170-
10. Select the **storageName** variable. Add the right bracket. The following example shows the outputs section:
170+
10. Select the **storageName** variable. Your code now looks like:
171+
172+
```json
173+
"storageUri": {
174+
"type": "string",
175+
"value": "[reference(variables('storageName'))"
176+
}
177+
```
178+
179+
11. The preceding code won't work because `reference` returns an object, but your output value is set to *string*. You need to specify one of the values on that object. The reference function can be used with any resource type, so VS Code doesn't suggest properties for the object. Instead, you can find that one value [returned for a storage account](/rest/api/storagerp/storageaccounts/getproperties) is `.primaryEndpoints.blob`.
180+
181+
Add that property after the last parenthesis. Add the right bracket. The following example shows the outputs section:
171182

172183
```json
173184
"outputs": {
@@ -177,7 +188,7 @@ This article builds on the template you created in [Create and deploy your first
177188
},
178189
"storageUri": {
179190
"type": "string",
180-
"value": "[reference(concat('Microsoft.Storage/storageAccounts/',variables('storageName'))).primaryEndpoints.blob]"
191+
"value": "[reference(variables('storageName')).primaryEndpoints.blob]"
181192
}
182193
}
183194
```
@@ -245,15 +256,15 @@ The final template is:
245256
},
246257
"storageUri": {
247258
"type": "string",
248-
"value": "[reference(concat('Microsoft.Storage/storageAccounts/',variables('storageName'))).primaryEndpoints.blob]"
259+
"value": "[reference(variables('storageName')).primaryEndpoints.blob]"
249260
}
250261
}
251262
}
252263
```
253264

254265
## Deploy template
255266

256-
You are ready to deploy this template. You use either PowerShell or Azure CLI to create a resource group. Then, you deploy a storage account to that resource group.
267+
You're ready to deploy this template. You use either PowerShell or Azure CLI to create a resource group. Then, you deploy a storage account to that resource group.
257268

258269
* For PowerShell, use the following commands from the folder containing the template:
259270

0 commit comments

Comments
 (0)