Remediation
From Azure Portal
- Go to
Storage accounts. - Click the name of a storage account with blob storage.
- In the
Overviewpage, on thePropertiestab, underBlob service, clickDisablednext toVersioning. - Under
Tracking, check the box next toEnable versioning for blobs. - Select the radio button next to
Keep all versions or Delete versions after (in days). - If selecting to delete versions, enter a number of in the box after which to delete blob versions.
- Click
Save. - Repeat steps 1-7 for each storage account with blob storage.
From Azure CLI
For each storage account requiring remediation, run the following command to enable blob versioning:
az storage account blob-service-properties update --account-name <storage-account> --enable-versioning true
From PowerShell
For each storage account requiring remediation, run the following command to enable blob versioning:
Update-AzStorageBlobServiceProperty -ResourceGroupName <resource-group> -StorageAccountName <storage-account> -IsVersioningEnabled $true