fix: Production 로그 누락 및 DB 마이그레이션 미적용 수정 (#277)
Some checks failed
SPMS_API/pipeline/head There was a failure building this commit
Some checks failed
SPMS_API/pipeline/head There was a failure building this commit
Reviewed-on: https://git.ipstein.myds.me/SPMS/SPMS_API/pulls/278
This commit is contained in:
commit
bb748a66a3
|
|
@ -73,7 +73,14 @@ builder.Services.AddRateLimiter(options =>
|
|||
|
||||
var app = builder.Build();
|
||||
|
||||
// ===== 5. Middleware Pipeline =====
|
||||
// ===== 5. DB 마이그레이션 자동 적용 =====
|
||||
using (var scope = app.Services.CreateScope())
|
||||
{
|
||||
var db = scope.ServiceProvider.GetRequiredService<SPMS.Infrastructure.AppDbContext>();
|
||||
await db.Database.MigrateAsync();
|
||||
}
|
||||
|
||||
// ===== 6. Middleware Pipeline =====
|
||||
app.UseMiddlewarePipeline();
|
||||
|
||||
app.Run();
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@
|
|||
}
|
||||
},
|
||||
"WriteTo": [
|
||||
{ "Name": "Console" },
|
||||
{
|
||||
"Name": "File",
|
||||
"Args": {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user