CmdID / az / az storage / az storage azcopy / az storage azcopy blob
az storage azcopy blob delete
Delete blobs from a storage blob container using AzCopy. Azure CLI extensions reference
3 examples 3 options Its page in the Azure CLI extensions reference
Examples
Delete a single blob from a container.
az storage azcopy blob delete -c MyContainer --account-name MyStorageAccount -t TargetBlobIdentify-cThe delete target container.-tThe delete target path.Delete all blobs from a container.
az storage azcopy blob delete -c MyContainer --account-name MyStorageAccount --recursiveIdentify-cThe delete target container.--recursiveRecursively delete blobs.Delete all blobs in a virtual directory.
az storage azcopy blob delete -c MyContainer --account-name MyStorageAccount -t "path/to/virtual_directory" --recursiveIdentify-cThe delete target container.-tThe delete target path.--recursiveRecursively delete blobs.Options
--container, -cThe delete target container.--recursive, -rRecursively delete blobs.--target, -tThe delete target path.