-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update packages | Improved key handling
- Loading branch information
1 parent
86037b8
commit 1eefc67
Showing
6 changed files
with
39 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
using Microsoft.Extensions.Configuration; | ||
// (c) 2024 Francesco Del Re <[email protected]> | ||
// This code is licensed under MIT license (see LICENSE.txt for details) | ||
using Microsoft.Extensions.Configuration; | ||
using Microsoft.Extensions.DependencyInjection; | ||
using PDNDClientAssertionGenerator.Configuration; | ||
using PDNDClientAssertionGenerator.Interfaces; | ||
|
@@ -16,9 +18,11 @@ public static class PDNDClientAssertionServiceExtensions | |
/// <returns>The updated IServiceCollection instance.</returns> | ||
public static IServiceCollection AddPDNDClientAssertionServices(this IServiceCollection services) | ||
{ | ||
// Use ConfigurationManager to load the configuration file (appsettings.json) | ||
// Use ConfigurationManager to load the configuration file (appsettings.json or environment variables) | ||
var configuration = new ConfigurationManager() | ||
.AddJsonFile("appsettings.json", optional: false, reloadOnChange: true) // Load configuration | ||
.SetBasePath(Directory.GetCurrentDirectory()) | ||
.AddJsonFile("appsettings.json", optional: false, reloadOnChange: true) | ||
.AddEnvironmentVariables() | ||
.Build(); | ||
|
||
// Ensure that the configuration contains required sections and values | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters