mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
support appsettings.Development.json override
This commit is contained in:
parent
814b875aa1
commit
dc6605374e
2 changed files with 6 additions and 0 deletions
|
|
@ -44,6 +44,9 @@ private static void AddConfiguration(this IServiceCollection services)
|
|||
var config = new ConfigurationBuilder()
|
||||
.AddEnvironmentVariables()
|
||||
.AddJsonFile("appsettings.json", true, true)
|
||||
#if DEBUG
|
||||
.AddJsonFile("appsettings.Development.json", true, true)
|
||||
#endif
|
||||
.Build();
|
||||
services.Configure<ApplicationInsights>(config.GetSection(nameof(ApplicationInsights)));
|
||||
services.Configure<ConnectionStrings>(config.GetSection(nameof(ConnectionStrings)));
|
||||
|
|
|
|||
|
|
@ -48,6 +48,9 @@
|
|||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="appsettings.Development.json">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
<None Update="appsettings.json">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
</None>
|
||||
|
|
|
|||
Loading…
Reference in a new issue