mirror of
https://github.com/bitwarden/server
synced 2025-12-24 04:03:25 +00:00
added application insights to api
This commit is contained in:
@@ -38,6 +38,7 @@ namespace Bit.Api
|
||||
if(env.IsDevelopment())
|
||||
{
|
||||
builder.AddUserSecrets();
|
||||
builder.AddApplicationInsightsSettings(developerMode: true);
|
||||
}
|
||||
|
||||
builder.AddEnvironmentVariables();
|
||||
@@ -49,6 +50,8 @@ namespace Bit.Api
|
||||
|
||||
public void ConfigureServices(IServiceCollection services)
|
||||
{
|
||||
services.AddApplicationInsightsTelemetry(Configuration);
|
||||
|
||||
var provider = services.BuildServiceProvider();
|
||||
|
||||
// Options
|
||||
@@ -164,6 +167,9 @@ namespace Bit.Api
|
||||
globalSettings.Loggr.ApiKey);
|
||||
}
|
||||
|
||||
app.UseApplicationInsightsRequestTelemetry();
|
||||
app.UseApplicationInsightsExceptionTelemetry();
|
||||
|
||||
// Add static files to the request pipeline.
|
||||
app.UseStaticFiles();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user