SodaPop.ConfigExplorer
1.0.0
See the version list below for details.
dotnet add package SodaPop.ConfigExplorer --version 1.0.0
NuGet\Install-Package SodaPop.ConfigExplorer -Version 1.0.0
<PackageReference Include="SodaPop.ConfigExplorer" Version="1.0.0" />
paket add SodaPop.ConfigExplorer --version 1.0.0
#r "nuget: SodaPop.ConfigExplorer, 1.0.0"
// Install SodaPop.ConfigExplorer as a Cake Addin #addin nuget:?package=SodaPop.ConfigExplorer&version=1.0.0 // Install SodaPop.ConfigExplorer as a Cake Tool #tool nuget:?package=SodaPop.ConfigExplorer&version=1.0.0
Config Explorer for ASPNET Core
Platform | Status |
---|---|
Windows | |
Linux |
Install
Nuget
Install-Package SodaPop.ConfigExplorer
dotnet CLI
dotnet add package SodaPop.ConfigExplorer
Configuration
if (env.IsDevelopment)
{
//config is the `IConfigurationRoot` from your `ConfigurationBuilder`
app.UseConfigExplorer(config);
}
Once configured, access a diagnostic listing of all the available keys and values in the configuration system via:
http://localhost:port/config
A Strong Warning On Security
Configuration can often contain application secrets such as connection strings. As a precautionary measure the end point will only load if the host is localhost
and we will also filter out any configuration key which has a name containing ConnectionString
. Even with these set, we strongly advise this middleware is only added in development environments.
Example
Whats It Do?
The configuration system in AspNet Core is extremely flexible, but it sometimes can be hard to know what value you're going to receive. An example configuration might look like:
var config = new ConfigurationBuilder()
.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{env.EnvironmentName}.json")
.AddJsonFile("someotherappsetting.json", optional: true)
.AddInMemoryCollection()
.AddEnvironmentVariables()
.Add(MyCustomSource)
.Build();
Depending on where you're running, what environment variables are set on the current machine, which configuration options you're using, what order the configuration items are added, which files are present or not present can result in you getting different configuration.
Compounding this, there are a number of "magic" prefixes used to hook in for Azure integration.
This tool will simply list out all the keys and values currently available in the entire configuration system.
Available Options
app.UseConfigExplorer(config, new ConfigExplorerOptions //optional
{
LocalHostOnly = true, //default
PathMatch = "/config", //default
TryRedactConnectionStrings = true //default
});
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
.NET Core | netcoreapp1.0 was computed. netcoreapp1.1 was computed. netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard1.6 is compatible. netstandard2.0 was computed. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen30 was computed. tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 1.6
- Microsoft.AspNetCore (>= 1.0.3)
- NETStandard.Library (>= 1.6.1)
- RazorLight (>= 1.0.0-rc2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.