Skip to content

Latest commit

 

History

History
64 lines (49 loc) · 3.14 KB

File metadata and controls

64 lines (49 loc) · 3.14 KB

Ramstack.FileSystem.Azure

NuGet MIT

Provides an implementation of Ramstack.FileSystem based on Azure Blob Storage.

Getting Started

To install the Ramstack.FileSystem.Azure NuGet package in your project, run the following command:

dotnet add package Ramstack.FileSystem.Azure

Usage

using Ramstack.FileSystem.Azure;

string connectionString = "...";
AzureFileSystem fs = new AzureFileSystem(connectionString, containerName: "storage");

// Create Azure container if it doesn't exist
await fs.CreateContainerAsync(PublicAccessType.None);

await foreach (VirtualFile file in fs.GetFilesAsync("/"))
{
    Console.WriteLine(node.Name);
}

You can also configure the file system to be read-only:

AzureFileSystem fs = new AzureFileSystem(connectionString, containerName: "storage")
{
    IsReadOnly = true
};

Related Projects

Supported Versions

Version
.NET 6, 7, 8, 9, 10

Contributions

Bug reports and contributions are welcome.

License

This package is released as open source under the MIT License. See the LICENSE file for more details.