On this page

Saving to Azure Blob

Introduction

This tutorial is designed to guide you through the process of saving files to Azure Blob Storage, a cloud storage service from Microsoft Azure.

By the end of this tutorial, you'll be able to set up a destination object for saving files to Azure Blob Storage, understanding the necessary parameters for configuration.

Supported Protocols

ProtocolDescription
azblob://Azure Blob Storage Protocol

1
Creating a Blob Storage Container

  1. Log into the Azure portal and navigate to the Azure Storage Account service.
  2. Create a new storage account or use an existing one.
  3. Inside the storage account, create a new blob container.

Please see Manage blob containers using the Azure portal - Azure Storage for more details.

2
Getting Your Azure Blob Credentials

  1. In the Azure portal, go to the storage account you want to use.
  2. Under "Access keys", find the 'Storage account name' and 'Key'; these are your credentials.

3
Saving Output to Azure Blob

In order to save your outputs to your Azure Blob Storage, define your destination object using the following structure.

Destination Object Structure

"destination": {
  "url": "azblob://endpoint/blob_container/path",
  "key": "storage_account_name",
  "secret": "storage_account_key"
}

Attributes of Azure Blob Destination Object

AttributeDescription
urlYour Azure Blob Destination URL. Includes the endpoint, blob container, and path.
keyYour Azure Storage account name.
secretYour Azure Storage account key.
secretYour Azure Storage account key.

URL Structure for Azure Blob

The url used for your Azure Blob Storage destination object consists of endpoint, blob container, and path if applicable. Check the examples for single file and ABR formats like HLS and DASH below:

azblob://[endpoint]/[blob_container]/[path]

When saving ABR outputs like HLS or DASH, please specify the path to a folder where the contents of the HLS or DASH stream should be located:

"destination": {
  "url": "azblob://[endpoint]/[blob_container]/folder"
}

Components of URL

endpointTypically "core.windows.net" or any other custom domain name if set up by the client.
blob_containerThe name of your blob container in Azure Storage.
pathPath where the file will be saved inside the blob container.

Destination Object Example

"destination": {
  "url": "azblob://core.windows.net/my-blob-container/folder/output.mp4",
  "key": "myStorageAccount",
  "secret": "myStorageAccountKey"
}

"destination": {
  "url": "azblob://core.windows.net/my-blob-container/folder",
  "key": "myStorageAccount",
  "secret": "myStorageAccountKey"
}

Considerations

  • Access Control: Configure access policies in Azure to control who can access your blob storage.

  • Blob Types: Understand the different types of blobs (block, append, page) for appropriate usage.

  • Authentication Errors: Double-check your storage account name and key for accuracy.

  • Blob Container Access: Ensure the blob container exists and has the correct access level set.

  • Explore advanced Azure Blob Storage features like automated lifecycle management and hierarchical namespace.