azure-oss / storage-blob-laravel
Azure Storage Blob filesystem driver for Laravel
Package info
github.com/Azure-OSS/azure-storage-php-adapter-laravel
pkg:composer/azure-oss/storage-blob-laravel
Requires
- php: ^8.1
- azure-oss/storage-blob-flysystem: ^1.2
- illuminate/filesystem: ^10|^11|^12|^13
- illuminate/support: ^10|^11|^12|^13
README
Community-driven PHP SDKs for Azure, because Microsoft won't.
In November 2023, Microsoft officially archived their Azure SDK for PHP and stopped maintaining PHP integrations for most Azure services. No migration path, no replacement — just a repository marked read-only.
We picked up where they left off.
Our other packages:
-
azure-oss/storage – Azure Blob Storage SDK
-
azure-oss/storage-blob-flysystem – Flysystem adapter
Install
composer require azure-oss/storage-blob-laravel
Documentation
You can read the documentation here.
Quickstart
# config/filesystems.php 'azure' => [ 'driver' => 'azure-storage-blob', 'connection_string' => env('AZURE_STORAGE_CONNECTION_STRING'), 'container' => env('AZURE_STORAGE_CONTAINER'), ],
Authentication
Besides shared key via connection string, this driver supports additional authentication methods (like Entra ID / token-based credentials, managed identity, workload identity, and shared key via account key). See the docs for configuration examples: https://azure-oss.github.io/category/storage-blob-laravel/installation
use Illuminate\Support\Facades\Storage; $disk = Storage::disk('azure'); // Write $disk->put('docs/hello.txt', 'Hello from Laravel'); // Read $content = $disk->get('docs/hello.txt'); // Exists $exists = $disk->exists('docs/hello.txt'); // Copy / move $disk->copy('docs/hello.txt', 'docs/hello-copy.txt'); $disk->move('docs/hello-copy.txt', 'docs/hello-moved.txt'); // List $files = $disk->allFiles('docs'); // Delete $disk->delete('docs/hello-moved.txt');
License
This project is released under the MIT License. See LICENSE for details.