mirror of
https://github.com/bitwarden/server.git
synced 2025-07-04 01:22:50 -05:00
more logging
This commit is contained in:
@ -1,9 +1,13 @@
|
||||
using System.Globalization;
|
||||
using Bit.Core;
|
||||
using Bit.Core.Utilities;
|
||||
using Microsoft.AspNetCore.Builder;
|
||||
using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using Microsoft.IdentityModel.Logging;
|
||||
using Serilog.Events;
|
||||
|
||||
namespace Bit.EventsProcessor
|
||||
{
|
||||
@ -25,12 +29,15 @@ namespace Bit.EventsProcessor
|
||||
services.AddHostedService<AzureQueueHostedService>();
|
||||
}
|
||||
|
||||
public void Configure(IApplicationBuilder app, IHostingEnvironment env)
|
||||
public void Configure(
|
||||
IApplicationBuilder app,
|
||||
IHostingEnvironment env,
|
||||
ILoggerFactory loggerFactory,
|
||||
IApplicationLifetime appLifetime,
|
||||
GlobalSettings globalSettings)
|
||||
{
|
||||
if(env.IsDevelopment())
|
||||
{
|
||||
IdentityModelEventSource.ShowPII = true;
|
||||
}
|
||||
IdentityModelEventSource.ShowPII = true;
|
||||
loggerFactory.AddSerilog(app, env, appLifetime, globalSettings, (e) => e.Level >= LogEventLevel.Warning);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,3 +1,11 @@
|
||||
{
|
||||
"azureStorageConnectionString": "SECRET"
|
||||
"azureStorageConnectionString": "SECRET",
|
||||
"globalSettings": {
|
||||
"selfHosted": false,
|
||||
"projectName": "Events Processor",
|
||||
"documentDb": {
|
||||
"uri": "SECRET",
|
||||
"key": "SECRET"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user