PouryaKit
ReferencePackages

PouryaKit.Storage.S3

The Host's file storage on Amazon S3 or an S3-compatible store such as MinIO.

The Host's file storage on Amazon S3 or an S3-compatible store such as MinIO. It supplies IFileStorage of PouryaKit.Storage on the AWS SDK, from options the Host validates, so Feature code stays on the contract and never names the SDK.

Install

dotnet add package PouryaKit.Storage.S3 --prerelease

When to use it

  • The application keeps its files on S3.
  • You run an S3-compatible store, such as MinIO or RustFS.

It implements PouryaKit.Storage. A Host composes one provider, so it replaces PouryaKit.Storage.AzureBlob rather than sitting beside it.

Quick start

Bind the provider's options from configuration, then register it in the Host, as the Proving Sample does:

builder.Services.Configure<PouryaKitS3StorageOptions>(
    builder.Configuration.GetSection("PouryaKit:Storage:S3")
);
builder.Services.AddPouryaKitS3Storage();

What you get

  • The contract of IFileStorage on the AWS SDK.
  • Options validated, so a Host with a wrong setting does not serve.
  • Presigned links signed by the SDK.
  • S3-compatible stores on the same provider.

A link signed with temporary credentials, such as an instance role's, stops working when they expire, whatever lifetime was asked for.

Learn more

On this page