Skip to content

Commit

Permalink
Try to reduce log spamming (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
Seji64 committed Oct 12, 2023
1 parent db73e09 commit 3fc665d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,14 @@
using MudBlazor;
using MudBlazor.Services;
using Serilog;
using Serilog.Events;

var builder = WebApplication.CreateBuilder(args);

builder.Host.UseSerilog((ctx, lc) => lc
.MinimumLevel.Override("Microsoft", LogEventLevel.Warning)
.Enrich.FromLogContext()
.WriteTo.Console()
.WriteTo.Console());

// Add services to the container.
Expand Down Expand Up @@ -44,13 +48,12 @@
}

app.UseHttpsRedirection();

app.UseStaticFiles();

app.UseRouting();

app.MapBlazorHub();
app.MapFallbackToPage("/_Host");
app.MapHealthChecks("/healthz");

app.UseSerilogRequestLogging();
app.Run();

0 comments on commit 3fc665d

Please sign in to comment.