feat: add fnOS packaging, storage workflows and release pipeline

This commit is contained in:
2026-08-11 18:05:49 +08:00
parent c5922f9b08
commit 95932f0199
181 changed files with 24024 additions and 1164 deletions
+27
View File
@@ -0,0 +1,27 @@
using dy.net.model.dto;
namespace dy.net.storage
{
public interface IMediaStorage
{
StorageType StorageType { get; }
Task EnsureDirectoryAsync(string path, CancellationToken cancellationToken = default);
Task<bool> ExistsAsync(string path, CancellationToken cancellationToken = default);
Task<long?> GetLengthAsync(string path, CancellationToken cancellationToken = default);
Task WriteAsync(string path, Stream source, long? contentLength = null, string contentType = null, CancellationToken cancellationToken = default);
Task<StorageReadResult> OpenReadAsync(string path, long? from = null, long? to = null, CancellationToken cancellationToken = default);
Task DeleteAsync(string path, CancellationToken cancellationToken = default);
}
/// <summary>
/// Optional capability for providers that expose a canonical path spelling different from
/// the logical path requested by the application.
/// </summary>
public interface ICanonicalMediaStorage
{
Task<string> CanonicalizePathAsync(
string path,
bool createParentDirectories = false,
CancellationToken cancellationToken = default);
}
}