From fb736a1c34d6a0522bc8d8b3bb702711e5668200 Mon Sep 17 00:00:00 2001 From: Polianin Nikita Date: Tue, 28 May 2024 06:49:40 +0300 Subject: [PATCH] feat: use path wrapper --- Endpoint/Program.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Endpoint/Program.cs b/Endpoint/Program.cs index 7c34446..bb7b69b 100644 --- a/Endpoint/Program.cs +++ b/Endpoint/Program.cs @@ -8,6 +8,7 @@ using Microsoft.Extensions.Hosting; using Microsoft.Extensions.Options; using Mirea.Api.DataAccess.Application; using Mirea.Api.DataAccess.Persistence; +using Mirea.Api.Endpoint.Common.Services; using Mirea.Api.Endpoint.Configuration; using Mirea.Api.Endpoint.Properties; using Mirea.Api.Endpoint.Configuration.Swagger; @@ -42,7 +43,8 @@ public class Program var builder = WebApplication.CreateBuilder(args); builder.Configuration.AddConfiguration(ConfigureEnvironment()); - builder.Configuration.AddJsonFile(Settings.FilePath, optional: true, reloadOnChange: true); + builder.Configuration.AddJsonFile(PathBuilder.Combine(GeneralConfig.FilePath), optional: true, reloadOnChange: true); + builder.Services.Configure(builder.Configuration); builder.Services.AddApplication(); builder.Services.AddPersistence(builder.Configuration.Get()?.DbSettings?.ConnectionStringSql ?? string.Empty);