Refactored starup pipeline #75

Merged
khwezi merged 1 commits from cart into main 2026-06-14 12:23:56 +02:00
+2 -1
View File
@@ -49,6 +49,8 @@ builder.Services.Configure<ForwardedHeadersOptions>(options =>
var app = builder.Build();
app.UseForwardedHeaders();
using var security = app.Services.CreateScope();
{
var dataProtectionContext = security.ServiceProvider.GetRequiredService<DataProtectionDbContext>();
@@ -56,7 +58,6 @@ using var security = app.Services.CreateScope();
await dataProtectionContext.Database.MigrateAsync();
}
app.UseForwardedHeaders();
app.AddSecurityEndpoints();
var schedulerFactory = app.Services.GetRequiredService<ISchedulerFactory>();