- Changed Serilog configuration file from `appsettings.json` to `appsettings.Logging.json`. - Added logging for application startup. - Dynamically load environment-specific appsettings JSON files, excluding `Development` and `migration` files.
81 lines
2.7 KiB
JSON
81 lines
2.7 KiB
JSON
{
|
|
"Serilog": {
|
|
"Using": [ "Serilog.Sinks.Console", "Serilog.Sinks.File" ],
|
|
"MinimumLevel": {
|
|
"Default": "Verbose",
|
|
"Override": {
|
|
"Microsoft": "Warning",
|
|
"System": "Warning"
|
|
}
|
|
},
|
|
"WriteTo": [
|
|
{
|
|
"Name": "Console",
|
|
"Args": {
|
|
"outputTemplate": "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Verbose-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Verbose",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Debug-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Debug",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Info-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Information",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Warning-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Warning",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Error-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Error",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
},
|
|
{
|
|
"Name": "File",
|
|
"Args": {
|
|
"path": "E:/LogFiles/Digital Data/signFlow.Finalizer/log.Fatal-.txt",
|
|
"rollingInterval": "Day",
|
|
"restrictedToMinimumLevel": "Fatal",
|
|
"retainedFileCountLimit": 30,
|
|
"outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}"
|
|
}
|
|
}
|
|
],
|
|
"Enrich": [ "FromLogContext", "WithMachineName", "WithThreadId" ]
|
|
}
|
|
} |