WIP: build production images
Some checks failed
Build Docker Images / build-and-push (push) Failing after 1m30s

This commit is contained in:
Michał Zieliński
2025-10-12 20:17:33 +02:00
parent b24aaab679
commit 140ece8080
12 changed files with 275 additions and 72 deletions

View File

@@ -100,13 +100,19 @@ app.UseAuthorization();
app.UseAuthorization();
app.MapControllers();
app.MapGet("/health", () => Results.Ok(new { status = "OK", timestamp = DateTime.UtcNow }))
.AllowAnonymous();
RecurringJob.AddOrUpdate<ProductSyncJob>(
"product-sync",
job => job.ExecuteAsync(),
Cron.Daily(2, 0), // Every day at 2:00 AM
new RecurringJobOptions
{
TimeZone = TimeZoneInfo.Local
TimeZone = TimeZoneInfo.Local,
MisfireHandling = app.Environment.IsDevelopment()
? MisfireHandlingMode.Relaxed
: MisfireHandlingMode.Strict
});
app.Run();