feat(web): add local portfolio cover storage

This commit is contained in:
2026-06-02 12:35:00 +03:00
parent 7d1489445e
commit e5945288ac
11 changed files with 575 additions and 1 deletions
+4
View File
@@ -2,6 +2,7 @@ using GmRelay.Web;
using GmRelay.Web.Components;
using GmRelay.Web.Health;
using GmRelay.Web.Services;
using GmRelay.Web.Services.Portfolio.Covers;
using Microsoft.AspNetCore.Authentication.Cookies;
using Microsoft.AspNetCore.Authentication;
using Microsoft.AspNetCore.DataProtection;
@@ -37,6 +38,7 @@ builder.AddNpgsqlDataSource("gmrelaydb");
// Add Services
builder.Services.AddSingleton<TelegramAuthService>();
builder.Services.AddPortfolioCoverStorage(builder.Configuration);
builder.Services.Configure<DiscordOAuthOptions>(builder.Configuration.GetSection("Discord"));
builder.Services.AddSingleton<DiscordAuthService>();
builder.Services.AddSingleton<DiscordOAuthStateStore>();
@@ -94,6 +96,8 @@ app.Use(async (context, next) =>
await next();
});
app.UsePortfolioCoverFiles();
app.UseAuthentication();
app.UseAuthorization();
app.UseAntiforgery();