Back to Distribution

Microsoft Azure storage driver

docs/content/storage-drivers/azure.md

3.1.16.0 KB
Original Source

An implementation of the storagedriver.StorageDriver interface which uses Microsoft Azure Blob Storage for object storage.

Parameters

ParameterRequiredDescription
accountnameyesName of the Azure Storage Account.
accountkeyyesPrimary or Secondary Key for the Storage Account.
containeryesName of the Azure root storage container in which all registry data is stored. Must comply the storage container name requirements. For example, if your url is https://myaccount.blob.core.windows.net/myblob use the container value of myblob.
credentialsyesAzure credentials used to authenticate with Azure blob storage.
rootdirectorynoThis is a prefix that is applied to all Azure keys to allow you to segment data in your container if necessary.
realmnoDomain name suffix for the Storage Service API endpoint. For example realm for "Azure in China" would be core.chinacloudapi.cn and realm for "Azure Government" would be core.usgovcloudapi.net. By default, this is core.windows.net.
max_retriesnoMax retries for driver operation status. Retries use a simple backoff algorithm where each retry number is multiplied by retry_delay, and this number is used as the delay. Set to -1 to disable retries and abort if the copy does not complete immediately. Defaults to 5.
retry_delaynoTime to wait between retries for driver operation status. This time is multiplied by N on each retry, where N is the retry number. Defaults to 100ms

Credentials

ParameterRequiredDescription
typeyesAzure credentials used to authenticate with Azure blob storage (client_secret, shared_key, default_credentials).
clientidnoThe unique application ID of this application in your directory. Required if not using Workload Identity.
tenantidnoAzure Active Directory’s global unique identifier. Required if not using Workload Identity.
secretnoA secret string that the application uses to prove its identity when requesting a token. Required if not using Workload Identity.

Azure managed identity

To use managed identity to access Azure blob storage you can use Microsoft Bicep.

The following configures credentials that the Azure storage driver will use to construct AZ Identity to access the blob storage:

properties: {
  azure: {
    accountname: accountname
    container: containername
    credentials: {
      type: default
    }
  }
}

Azure workload identity

If running in an AKS cluster with Azure workload identity, use the default_credentials type. There's no need to set the other credentials fields. The service account will need at least Storage Blob Data Contributor role on the storage account to read and write to it.