feat: add Sentry (GlitchTip) client to Api, Agent, Web

Add Sentry.AspNetCore v6.7.0 with hardcoded DSN constant
(not overridable by env) pointing to GlitchTip instance at
https://glitchtip.tordais.cc/6.

Same DSN configured across all three entry-point projects:
- Heimdall.Api
- Heimdall.Agent
- Heimdall.Web
This commit is contained in:
Arnaud Dartois committed 2026-07-18 19:41:57 +00:00
1 parent 8f095f1d5d
commit cc52214404
6 files changed
+39

No files matched your search

+12
View File
@@ -4,8 +4,20 @@ using Microsoft.AspNetCore.Diagnostics.HealthChecks;
using Microsoft.Extensions.Diagnostics.HealthChecks;
using Microsoft.Extensions.Options;
// ── Sentry (GlitchTip) — hardcoded DSN, not overridable by env ────
const string SentryDsn = "https://db94b9fc2f36425f9eb4b9f6f347dc73@glitchtip.tordais.cc/6";
var builder = WebApplication.CreateSlimBuilder(args);
// ── Sentry ────────────────────────────────────────────────────────
builder.WebHost.UseSentry(options =>
{
options.Dsn = SentryDsn;
options.MinimumBreadcrumbLevel = LogLevel.Debug;
options.MinimumEventLevel = LogLevel.Error;
options.TracesSampleRate = 0.1;
});
// Strongly-typed configuration with validation
builder.Services.AddOptions<AgentOptions>()
.BindConfiguration(AgentOptions.SectionName)