Skip to content

Add Azure Blob Storage support for cache

Stan Hu requested to merge sh-add-azure-cache-support into master

Based on top of !2378 (merged)

After the dependent MR is merged, change target branch to master and remove the Draft status.


This merge request makes it possible to use Azure Blob Storage as a runner cache. Currently customers wanting to use Azure Blob Storage have to set up a Minio Gateway (https://docs.gitlab.com/charts/advanced/external-object-storage/azure-minio-gateway.html), which isn't ideal because it requires customers to maintain their own proxy server for Azure. We have a number of customers who want native support for Azure Blob Storage.

Azure Blob Storage will be fully supported for storing LFS, CI artifacts, uploads, packages, etc. in 13.4 (gitlab#25877 (closed)).

One wrinkle in supporting pre-signed URLs with Azure is that the PUT Blob API (https://docs.microsoft.com/en-us/rest/api/storageservices/put-blob) requires the x-ms-blob-type HTTP header, which cannot be sent via a query string. This merge request adds a new method in the cache adapter to allow for custom, unsigned HTTP headers. These headers are passed via the --header parameter to the cache archiver process. The default behavior of adding Content-Type and Last-Modified headers is retained if the --header parameters is omitted.

Closes #6612 (closed)

Edited by Stan Hu

Merge request reports