mirror of
https://github.com/LD-Reborn/Berufsschule_HAM.git
synced 2025-12-20 15:01:56 +00:00
Added asset id counter to migrations, fixed migrations async issue
This commit is contained in:
@@ -32,7 +32,7 @@ builder.Services.AddElmah<XmlFileErrorLog>(Options =>
|
||||
});
|
||||
|
||||
builder.Services.AddSingleton<LdapService>();
|
||||
builder.Services.AddSingleton<MigrationService>();
|
||||
builder.Services.AddHostedService<MigrationService>();
|
||||
|
||||
builder.Services.AddHealthChecks()
|
||||
.AddCheck<DatabaseHealthCheck>("DatabaseHealthCheck");
|
||||
@@ -123,8 +123,5 @@ app.MapControllerRoute(
|
||||
app.MapHealthChecks("/healthz")
|
||||
.RequireAuthorization();
|
||||
|
||||
// Run migrations
|
||||
using var scope = app.Services.CreateScope();
|
||||
var migrationService = scope.ServiceProvider.GetRequiredService<MigrationService>();
|
||||
|
||||
app.Run();
|
||||
|
||||
Reference in New Issue
Block a user