diff options
Diffstat (limited to 'code/api/src/Program.cs')
| -rw-r--r-- | code/api/src/Program.cs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/code/api/src/Program.cs b/code/api/src/Program.cs index aa7cae3..5eed813 100644 --- a/code/api/src/Program.cs +++ b/code/api/src/Program.cs @@ -41,6 +41,7 @@ using IOL.GreatOffice.Api.Jobs; using Microsoft.AspNetCore.HttpOverrides; using Microsoft.AspNetCore.Mvc.Versioning; using Quartz; +using Serilog.Events; namespace IOL.GreatOffice.Api; @@ -58,8 +59,11 @@ public static class Program var vaultService = builder.Services.BuildServiceProvider().GetRequiredService<VaultService>(); var configuration = vaultService.GetCurrentAppConfiguration(); var logger = new LoggerConfiguration() - .Enrich.FromLogContext() - .ReadFrom.Configuration(builder.Configuration) + .MinimumLevel.Information() + .MinimumLevel.Override("Microsoft", LogEventLevel.Information) + .MinimumLevel.Override("Microsoft.Hosting.Lifetime", LogEventLevel.Information) + .MinimumLevel.Override("Microsoft.EntityFrameworkCore", LogEventLevel.Information) + .MinimumLevel.Override("Microsoft.AspNetCore", LogEventLevel.Warning) .WriteTo.Console(); if (!builder.Environment.IsDevelopment() && configuration.SEQ_API_KEY.HasValue() && configuration.SEQ_API_URL.HasValue()) { |
