Skip to content

Commit e3cd5fe

Browse files
committed
update
1 parent 11973a3 commit e3cd5fe

File tree

1 file changed

+20
-18
lines changed

1 file changed

+20
-18
lines changed

articles/azure-resource-manager/templates/quickstart-create-template-specs.md

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ An Azure account with an active subscription. [Create an account for free](https
2323
2424
## Create template
2525

26-
You create a template spec from an ARM template. Copy the following template and save as **c:\Templates\createStorage.json**.
26+
You create a template spec from an ARM template. Copy the following template and save as **C:\Templates\createStorage.json**.
2727

2828
```json
2929
{
@@ -79,7 +79,7 @@ The template spec is a resource type named `Microsoft.Resources/templateSpecs`.
7979
-Version "1.0" `
8080
-ResourceGroupName templateSpecRG `
8181
-Location westus2 `
82-
-TemplateFile "c:\Templates\createStorage.json"
82+
-TemplateFile "C:\Templates\createStorage.json"
8383
```
8484
8585
# [CLI](#tab/azure-cli)
@@ -100,7 +100,7 @@ The template spec is a resource type named `Microsoft.Resources/templateSpecs`.
100100
--version "1.0" \
101101
--resource-group templateSpecRG \
102102
--location "westus2" \
103-
--template-file "c:\Templates\createStorage.json"
103+
--template-file "C:\Templates\createStorage.json"
104104
```
105105
106106
# [Portal](#tab/azure-portal)
@@ -139,7 +139,7 @@ The template spec is a resource type named `Microsoft.Resources/templateSpecs`.
139139
> [!NOTE]
140140
> Instead of using an ARM template, we recommend that you use PowerShell or CLI to create your template spec. Those tools automatically convert linked templates to artifacts connected to your main template. When you use an ARM template to create the template spec, you must manually add those linked templates as artifacts, which can be complicated.
141141
142-
1. When you use an ARM template to create the template spec, the template is embedded in the resource definition. There are some changes you need to make to your local template. Copy the following template and save it locally as **createTemplateSpec.json**.
142+
1. When you use an ARM template to create the template spec, the template is embedded in the resource definition. Copy the following template and save it locally as **createTemplateSpec.json**.
143143
144144
> [!NOTE]
145145
> In the embedded template, all [template expressions](template-expressions.md) must be escaped with a second left bracket. Use `"[[` instead of `"[`. JSON arrays still use a single left bracket.
@@ -158,7 +158,7 @@ The template spec is a resource type named `Microsoft.Resources/templateSpecs`.
158158
"displayName": "Storage template spec"
159159
}
160160
},
161-
{
161+
{
162162
"type": "Microsoft.Resources/templateSpecs/versions",
163163
"apiVersion": "2022-02-01",
164164
"name": "[format('{0}/{1}', 'storageSpec', '1.0')]",
@@ -223,13 +223,13 @@ The template spec is a resource type named `Microsoft.Resources/templateSpecs`.
223223
```azurepowershell
224224
New-AzResourceGroupDeployment `
225225
-ResourceGroupName templateSpecRG `
226-
-TemplateFile "c:\Templates\createTemplateSpec.json"
226+
-TemplateFile "C:\Templates\createTemplateSpec.json"
227227
```
228228
229229
```azurecli
230230
az deployment group create \
231231
--resource-group templateSpecRG \
232-
--template-file "c:\Templates\createTemplateSepc.json"
232+
--template-file "C:\Templates\createTemplateSepc.json"
233233
```
234234
235235
---
@@ -352,6 +352,8 @@ To deploy a template spec, use the same deployment commands as you would use to
352352
}
353353
```
354354
355+
In the template, **templateSpecRG** is the name of the resource group that contains the template spec, **storageSpec** is the name of the template spec, and **1.0** is the version of the template spec.
356+
355357
1. Use Azure CLI or PowerShell to create a new resource group for the storage account.
356358
357359
```azurepowershell
@@ -371,13 +373,13 @@ To deploy a template spec, use the same deployment commands as you would use to
371373
```azurepowershell
372374
New-AzResourceGroupDeployment `
373375
-ResourceGroupName storageRG `
374-
-TemplateFile "c:\Templates\storage.json"
376+
-TemplateFile "C:\Templates\storage.json"
375377
```
376378
377379
```azurecli
378380
az deployment group create \
379381
--resource-group storageRG \
380-
--template-file "c:\Templates\storage.json"
382+
--template-file "C:\Templates\storage.json"
381383
```
382384
383385
---
@@ -388,7 +390,7 @@ To let other users in your organization deploy your template spec, grant them re
388390
389391
## Update template
390392
391-
To make a change to the template in your template spec, use the following template. This template is similar to your earlier template except it adds a prefix for the storage account name. Copy the following template and update your `createStorage.json` file.
393+
To make a change to the template in your template spec, revise the template. The following template is similar to your earlier template except it adds a prefix for the storage account name. Copy the following template and update your `createStorage.json` file.
392394
393395
```json
394396
{
@@ -436,7 +438,7 @@ Instead of creating a new template spec for the revised template, add a new vers
436438
-Version "2.0" `
437439
-ResourceGroupName templateSpecRG `
438440
-Location westus2 `
439-
-TemplateFile "c:\Templates\createStorage.json"
441+
-TemplateFile "C:\Templates\createStorage.json"
440442
```
441443

442444
1. To deploy the new version, get the resource ID for the `2.0` version.
@@ -464,7 +466,7 @@ Instead of creating a new template spec for the revised template, add a new vers
464466
--version "2.0" \
465467
--resource-group templateSpecRG \
466468
--location "westus2" \
467-
--template-file "c:\Templates\createStorage.json"
469+
--template-file "C:\Templates\createStorage.json"
468470
```
469471

470472
1. To deploy the new version, get the resource ID for the `2.0` version.
@@ -509,7 +511,7 @@ Instead of creating a new template spec for the revised template, add a new vers
509511

510512
# [ARM Template](#tab/azure-resource-manager)
511513

512-
1. Again, you must make some changes to your local template to make it work with template specs. Copy the following template and save it locally as azuredeploy.json.
514+
1. Again, you must make some changes to your local template to make it work with template specs. Copy the following template and save it locally as **createTemplateSpec.json**.
513515

514516
```json
515517
{
@@ -525,7 +527,7 @@ Instead of creating a new template spec for the revised template, add a new vers
525527
"displayName": "Storage template spec"
526528
}
527529
},
528-
{
530+
{
529531
"type": "Microsoft.Resources/templateSpecs/versions",
530532
"apiVersion": "2022-02-01",
531533
"name": "[format('{0}/{1}', 'storageSpec', '1.0')]",
@@ -576,13 +578,13 @@ Instead of creating a new template spec for the revised template, add a new vers
576578
```azurepowershell
577579
New-AzResourceGroupDeployment `
578580
-ResourceGroupName templateSpecRG `
579-
-TemplateFile "c:\Templates\azuredeploy.json"
581+
-TemplateFile "C:\Templates\createTemplateSpec.json"
580582
```
581583

582584
```azurecli
583585
az deployment group create \
584586
--resource-group templateSpecRG \
585-
--template-file "c:\Templates\azuredeploy.json"
587+
--template-file "C:\Templates\createTemplateSpec.json"
586588
```
587589

588590
1. Copy the following template and save it locally to a file named **storage.json**.
@@ -614,13 +616,13 @@ Instead of creating a new template spec for the revised template, add a new vers
614616
```azurepowershell
615617
New-AzResourceGroupDeployment `
616618
-ResourceGroupName storageRG `
617-
-TemplateFile "c:\Templates\storage.json"
619+
-TemplateFile "C:\Templates\storage.json"
618620
```
619621

620622
```azurecli
621623
az deployment group create \
622624
--resource-group storageRG \
623-
--template-file "c:\Templates\storage.json"
625+
--template-file "C:\Templates\storage.json"
624626
```
625627

626628
---

0 commit comments

Comments
 (0)