Adds the ability to specify an appsettings file for user-jwts #58605
+222
−21
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds the ability to specify an appsettings file for user-jwts
Adds the ability to specify an appsettings file for user-jwts
Description
Currently the
user-jwts
tool amendsappsettings.Development.json
when adding a mock JWT scheme for local testing. Many people useappsettings.Development.json
for environments other than local development, i.e. a cloud Development environment, and so this amendment causes issues. In my particular case, we haveappsettings.Local.json
instead and so the tool fails to execute because it cannot findappsettings.Development.json
.As described in #56169 this affects multiple other teams too.
This PR allows for an appsettings file to be specified which will be amended instead of the default
appsettings.Development.json
. The tool still assumes the file lives next to the project, as it currently does, and checks that the file both exists and ends in.json
. Tests have been added to confirm the functionality.Fixes #56169