Created
December 13, 2021 11:18
-
-
Save JanneMattila/727f7282353d4ff6ce5d6fd7b16e9320 to your computer and use it in GitHub Desktop.
Azure Storage Account create & delete demo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Variables | |
resourceGroupName="rg-storage-demo-repeat" | |
# You can switch regions as you see fit | |
location="eastus" | |
#location="westeurope" | |
storageName="stor000000010" | |
# Create resource group for our demo | |
az group create --name $resourceGroupName --location $location | |
# Create storage account | |
az storage account create \ | |
--name $storageName \ | |
--resource-group $resourceGroupName \ | |
--location $location \ | |
--sku Standard_LRS \ | |
--https-only \ | |
-o table | |
# Delete storage account | |
az storage account delete \ | |
--name $storageName \ | |
--resource-group $resourceGroupName \ | |
--yes | |
# List storage account | |
az storage account list --resource-group $resourceGroupName -o table | |
# Wipe out the resources | |
az group delete --name $resourceGroupName -y |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment