fixes logging configuration

This commit is contained in:
Philipp Häfelfinger 2023-09-02 12:19:28 +02:00
parent 647a1e44bd
commit 8718b67176
2 changed files with 6 additions and 3 deletions

View File

@ -9,7 +9,10 @@ using PiwigoDirectorySync.Services;
using Spectre.Console.Cli;
var registrations = new ServiceCollection();
registrations.AddLogging(l => l.AddSimpleConsole(c =>
registrations.AddSingleton(AppSettings.Config);
registrations.AddLogging(l => l.AddConfiguration(AppSettings.Config.GetSection("Logging"))
.AddSimpleConsole(c =>
{
c.SingleLine = true;
c.IncludeScopes = true;

View File

@ -2,8 +2,8 @@
"Logging": {
"LogLevel": {
"Default": "Debug",
"System": "Information",
"Microsoft": "Information"
"System": "Warning",
"Microsoft": "Warning"
}
},
"ConnectionStrings": {