diff options
| author | x0vi <166640642+x0vi@users.noreply.github.com> | 2025-12-08 17:48:50 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-12-08 17:48:50 +0100 |
| commit | 2940b28785c6a548414fd684941e29d1e3a5b2d9 (patch) | |
| tree | 80f69a2ec785fc791e7c7581c370f805aec17895 /src/slskd/Program.cs | |
| parent | 15dee48db66f3bf0c8490aa1844bad0ba0371523 (diff) | |
| parent | f80fbac5eeda5901a106975446d0a11b7cbc38d6 (diff) | |
| download | slskd-2940b28785c6a548414fd684941e29d1e3a5b2d9.tar.gz | |
Merge branch 'master' into feature/configurable-ip-address
Diffstat (limited to 'src/slskd/Program.cs')
| -rw-r--r-- | src/slskd/Program.cs | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/slskd/Program.cs b/src/slskd/Program.cs index e693db63..a56c8afc 100644 --- a/src/slskd/Program.cs +++ b/src/slskd/Program.cs @@ -23,8 +23,6 @@ namespace slskd using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.DataAnnotations; - using System.Diagnostics; - using System.IO; using System.Linq; using System.Net; @@ -70,6 +68,7 @@ namespace slskd using slskd.Search; using slskd.Search.API; using slskd.Shares; + using slskd.Telemetry; using slskd.Transfers; using slskd.Transfers.Downloads; using slskd.Transfers.Uploads; @@ -91,6 +90,11 @@ namespace slskd public static readonly string AppName = "slskd"; /// <summary> + /// The DateTime of the 'genesis' of the application (the initial commit). + /// </summary> + public static readonly DateTime GenesisDateTime = new(2020, 12, 30, 6, 22, 0, DateTimeKind.Utc); + + /// <summary> /// The name of the local share host. /// </summary> public static readonly string LocalHostName = "local"; @@ -641,8 +645,9 @@ namespace slskd services.AddSingleton<EventService>(); services.AddSingleton<EventBus>(); - services.AddSingleton<TelemetryService>(); services.AddSingleton<PrometheusService>(); + services.AddSingleton<ReportsService>(); + services.AddSingleton<TelemetryService>(); services.AddSingleton<ScriptService>(); services.AddSingleton<WebhookService>(); @@ -905,6 +910,9 @@ namespace slskd }, }); + // allow endpoints marked with multiple content types in [Produces] to generate properly + options.OperationFilter<ContentNegotiationOperationFilter>(); + if (IOFile.Exists(XmlDocumentationFile)) { options.IncludeXmlComments(XmlDocumentationFile); |
