Restructure solution into folders and fix persistence issues
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
37987a394a
commit
7c39cb5562
62 files changed
+219
-151
No files matched your search
@@ -5,6 +5,7 @@ using Flypaper.Web.Auth;
|
||||
using Flypaper.Web.Components;
|
||||
using Microsoft.AspNetCore.Authentication.Cookies;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.DataProtection;
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
@@ -15,6 +16,12 @@ builder.Services.AddRazorComponents();
|
||||
builder.Services.AddFlypaperCore(builder.Configuration);
|
||||
builder.Services.AddFlypaperHttp(builder.Configuration);
|
||||
|
||||
var dataProtection = builder.Services.AddDataProtection().SetApplicationName("Flypaper");
|
||||
if (builder.Configuration["Flypaper:DataProtection:KeysPath"] is { Length: > 0 } keysPath)
|
||||
{
|
||||
dataProtection.PersistKeysToFileSystem(new DirectoryInfo(keysPath));
|
||||
}
|
||||
|
||||
builder.Services.Configure<AdminOptions>(builder.Configuration.GetSection(AdminOptions.SectionName));
|
||||
builder.Services.AddSingleton<AdminAuthenticator>();
|
||||
builder.Services
|
||||
|
||||
Reference in new issue
Block a user