[WIP] Switch configuration service to use standard configuration stores

features/nuget_autobuild
Matija Koželj 2 years ago
parent c9bb863108
commit d2d1f66cf6

@ -1,14 +1,18 @@
using Connected.Configuration.Authentication; using Connected.Configuration.Authentication;
using Connected.Configuration.Endpoints; using Connected.Configuration.Endpoints;
using Microsoft.Extensions.Configuration;
namespace Connected.Configuration; namespace Connected.Configuration;
internal class ConfigurationService : IConfigurationService internal class ConfigurationService : IConfigurationService
{ {
public ConfigurationService() public ConfigurationService(IConfiguration configuration)
{ {
Endpoint = new EndpointConfiguration(); Endpoint = new EndpointConfiguration();
configuration.Bind("endpoint", Endpoint);
Storage = new StorageConfiguration(); Storage = new StorageConfiguration();
configuration.Bind("storage", Storage);
} }
public IEndpointConfiguration Endpoint { get; } public IEndpointConfiguration Endpoint { get; }

Loading…
Cancel
Save