Skip to content

Commit 10a6383

Browse files
authored
Merge pull request #68142 from mumian/0228-storage-qs
[storage] add a section for creating storage account by using ARM
2 parents 5b2d8fd + 63f8ebb commit 10a6383

File tree

5 files changed

+60
-0
lines changed

5 files changed

+60
-0
lines changed

articles/storage/blobs/TOC.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
- name: Quickstarts
1515
items:
1616
- name: Create a storage account
17+
displayName: resource manager, resource manager template, template, ARM
1718
href: ../common/storage-quickstart-create-account.md?toc=%2fazure%2fstorage%2fblobs%2ftoc.json
1819
- name: Manage blobs without code
1920
items:
@@ -424,6 +425,7 @@
424425
- name: Import/Export
425426
href: /rest/api/storageimportexport
426427
- name: Resource Manager template
428+
displayName: ARM
427429
href: /azure/templates/microsoft.storage/allversions
428430
- name: Resources
429431
items:

articles/storage/common/storage-quickstart-create-account.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,10 @@ The button launches an interactive shell that you can use to run the steps in th
5151

5252
You can also install and use the Azure CLI locally. This quickstart requires that you are running the Azure CLI version 2.0.4 or later. Run `az --version` to find the version. If you need to install or upgrade, see [Install the Azure CLI](/cli/azure/install-azure-cli).
5353

54+
# [Template](#tab/template)
55+
56+
None.
57+
5458
---
5559

5660
## Log in to Azure
@@ -77,6 +81,10 @@ To log into your local installation of the CLI, run the login command:
7781
az login
7882
```
7983

84+
# [Template](#tab/template)
85+
86+
N/A
87+
8088
---
8189

8290
## Create a storage account
@@ -166,6 +174,33 @@ To create a general-purpose v2 storage account with zone-redundant storage (ZRS
166174
|Geo-redundant storage (GRS) |Standard_GRS |
167175
|Read-access geo-redundant storage (GRS) |Standard_RAGRS |
168176

177+
# [Template](#tab/template)
178+
179+
You can use either Azure Powershell or Azure CLI to deploy a Resource Manager template to create a storage account. The template used in this quickstart is from [Azure Quickstart templates](https://azure.microsoft.com/resources/templates/101-storage-account-create/). To run the scripts, select **Try it** to open the Azure Cloud shell. To paste the script, right-click the shell, and then select **Paste**.
180+
181+
```azurepowershell-interactive
182+
$resourceGroupName = Read-Host -Prompt "Enter the Resource Group name"
183+
$location = Read-Host -Prompt "Enter the location (i.e. centralus)"
184+
185+
New-AzResourceGroup -Name $resourceGroupName -Location "$location"
186+
New-AzResourceGroupDeployment -ResourceGroupName $resourceGroupName -TemplateUri "https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-storage-account-create/azuredeploy.json"
187+
```
188+
189+
```azurecli-interactive
190+
echo "Enter the Resource Group name:" &&
191+
read resourceGroupName &&
192+
echo "Enter the location (i.e. centralus):" &&
193+
read location &&
194+
az group create --name $resourceGroupName --location "$location" &&
195+
az group deployment create --resource-group $resourceGroupName --template-file "https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/101-storage-account-create/azuredeploy.json"
196+
```
197+
198+
To learn how to create templates, see:
199+
200+
- [Azure Resource Manager documentation](/azure/azure-resource-manager/).
201+
- [Storage account template reference](/azure/templates/microsoft.storage/allversions).
202+
- [Additional storage account template samples](https://azure.microsoft.com/resources/templates/?resourceType=Microsoft.Storage).
203+
169204
---
170205

171206
For more information about available replication options, see [Storage replication options](storage-redundancy.md).
@@ -198,6 +233,21 @@ To remove the resource group and its associated resources, including the new sto
198233
az group delete --name storage-quickstart-resource-group
199234
```
200235

236+
# [Template](#tab/template)
237+
238+
To remove the resource group and its associated resources, including the new storage account, use either Azure PowerShell or Azure CLI.
239+
240+
```azurepowershell-interactive
241+
$resourceGroupName = Read-Host -Prompt "Enter the Resource Group name"
242+
Remove-AzResourceGroup -Name $resourceGroupName
243+
```
244+
245+
```azurecli-interactive
246+
echo "Enter the Resource Group name:" &&
247+
read resourceGroupName &&
248+
az group delete --name $resourceGroupName
249+
```
250+
201251
---
202252

203253
## Next steps
@@ -219,4 +269,8 @@ In this quick start, you've created a general-purpose v2 standard storage accoun
219269
> [!div class="nextstepaction"]
220270
> [Work with blobs using the Azure CLI](../blobs/storage-quickstart-blobs-cli.md)
221271
272+
# [Template](#tab/template)
273+
274+
> [!div class="nextstepaction"]
275+
> [Work with blobs using the Azure portal](../blobs/storage-quickstart-blobs-portal.md)
222276
---

articles/storage/files/TOC.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@
200200
- name: Import/Export
201201
href: /rest/api/storageimportexport
202202
- name: Resource Manager template
203+
displayName: arm
203204
href: /azure/templates/microsoft.storage/allversions
204205
- name: Samples
205206
href: https://azure.microsoft.com/documentation/samples/?service=storage&term=file

articles/storage/queues/TOC.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- name: Quickstarts
99
items:
1010
- name: Create a storage account
11+
displayName: resource manager, resource manager template, template, ARM
1112
href: ../common/storage-quickstart-create-account.md?toc=%2fazure%2fstorage%2fqueues%2ftoc.json
1213
- name: Manage queues without code
1314
items:
@@ -200,6 +201,7 @@
200201
- name: Import/Export
201202
href: /rest/api/storageimportexport
202203
- name: Resource Manager template
204+
displayName: ARM
203205
href: /azure/templates/microsoft.storage/allversions
204206
- name: Resources
205207
items:

articles/storage/tables/TOC.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
- name: Quickstarts
1212
items:
1313
- name: Create a storage account
14+
displayName: resource manager, resource manager template, template, ARM
1415
href: /azure/storage/common/storage-quickstart-create-account
1516
maintainContext: true
1617
- name: Create a table in the Azure portal

0 commit comments

Comments
 (0)