mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-04 13:06:50 +00:00
feat: add logging to Seq
This commit is contained in:
parent
fbd036e9c4
commit
026a822c74
5 changed files with 96 additions and 70 deletions
|
|
@ -10,6 +10,7 @@ using Serilog;
|
|||
using Serilog.Events;
|
||||
using Serilog.Formatting.Compact;
|
||||
using Serilog.Sinks.Elasticsearch;
|
||||
using Serilog.Sinks.Seq;
|
||||
using Serilog.Sinks.SystemConsole.Themes;
|
||||
|
||||
using ILogger = Serilog.ILogger;
|
||||
|
|
@ -115,6 +116,15 @@ public class LoggingModule: Module
|
|||
logCfg.WriteTo.Elasticsearch(elasticConfig);
|
||||
}
|
||||
|
||||
if (config.SeqLogUrl != null)
|
||||
{
|
||||
logCfg.WriteTo.Seq(
|
||||
config.SeqLogUrl,
|
||||
restrictedToMinimumLevel: LogEventLevel.Verbose
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
_fn.Invoke(logCfg);
|
||||
return Log.Logger = logCfg.CreateLogger();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue