Add seq api key support
This commit is contained in:
@@ -34,7 +34,14 @@ public static class DependencyInjectionExtensions
|
||||
string? seqHost = builder.Configuration.GetConnectionString("seq");
|
||||
if (!string.IsNullOrEmpty(seqHost))
|
||||
{
|
||||
builder.AddSeqEndpoint("seq");
|
||||
builder.AddSeqEndpoint("seq", o =>
|
||||
{
|
||||
var apiKey = builder.Configuration.GetValue<string>("seq-api-key");
|
||||
if (!string.IsNullOrEmpty(apiKey))
|
||||
{
|
||||
o.ApiKey = apiKey;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
return builder;
|
||||
|
||||
Reference in New Issue
Block a user