-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathCreate_a_storage_account.azcli
29 lines (19 loc) · 1.09 KB
/
Create_a_storage_account.azcli
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
az login
az account show
az account list --all --output table
az account set --subscription "MSDN Platforms"
#First, create a new resource group
az group create --name storage-resource-group --location westeurope
#If you're not sure which region to specify for the --location parameter, you can retrieve a list of supported regions for your subscription
az account list-locations --query "[].{Region:name}" --out table
#Next, create a general-purpose v2 storage account with read-access geo-redundant storage
az storage account create --name twstacloud2020 --resource-group storage-resource-group --location westeurope --sku Standard_RAGRS --kind StorageV2
Replication option sku parameter
Locally redundant storage (LRS) Standard_LRS
Zone-redundant storage (ZRS) Standard_ZRS
Geo-redundant storage (GRS) Standard_GRS
Read-access geo-redundant storage (GRS) Standard_RAGRS
Geo-zone-redundant storage (GZRS) Standard_GZRS
Read-access geo-zone-redundant storage (RA-GZRS) Standard_RAGZRS
#Clean Up
az group delete --name storage-resource-group --yes