
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Delete Azure Blob File Using Azure CLI in PowerShell
To delete the Azure blob using Azure CLI, we can use “az storage blob” command with the “delete” parameter. Before running this command, we first need to make sure that the azure account is connected (az login) and the proper subscription is set (az account set).
To work with the azure storage account we need to authenticate to the storage. We can use storage key or the storage connections string. Here, we have shown how to retrieve the connections string.
$storageaccount = 'az204storage05june' $connectionstring = az storage account show-connection-string - n $storageaccount -otsv
The below command will delete the azure storage blob named ‘Test1.txt’ from the storage container container1.
az storage blob delete --account-name $storageaccount ` --container-name 'container1' ` --name 'Test1.txt' ` --connection-string $connectionstring --verbose
Advertisements