ApiSystem: fix autofac

This commit is contained in:
pavelbannov 2020-05-20 16:06:35 +03:00
parent a064da49f4
commit 85cec8fff2
3 changed files with 2 additions and 36 deletions

View File

@ -26,6 +26,7 @@
using System.Collections.Generic;
using System.IO;
using Microsoft.AspNetCore.Hosting;
using Microsoft.Extensions.Configuration;
using Microsoft.Extensions.Hosting;
@ -62,9 +63,7 @@ namespace ASC.ApiSystem
})
.AddJsonFile("appsettings.json")
.AddJsonFile($"appsettings.{hostingContext.HostingEnvironment.EnvironmentName}.json", true)
.AddJsonFile($"appsettings.services.json", true)
.AddJsonFile("storage.json")
.AddJsonFile("notify.json")
.AddJsonFile("kafka.json")
.AddJsonFile($"kafka.{hostingContext.HostingEnvironment.EnvironmentName}.json", true)
.AddEnvironmentVariables();

View File

@ -78,7 +78,7 @@ namespace ASC.ApiSystem
.AddSettingsController()
.AddTariffController();
services.AddAutofac(Configuration, HostEnvironment.ContentRootPath);
services.AddAutofac(Configuration, HostEnvironment.ContentRootPath, false);
}
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.

View File

@ -1,36 +1,3 @@
{
"pathToConf": "..\\..\\..\\config"
//"auth": {
// "allowskip": "false",
// "allowskip-registerportal": "true"
//},
//"core": {
// "base-domain": "localhost",
// "machinekey": "1123askdasjklasbnd\"",
// "notify": {
// "postman": "log"
// },
// "payment-partners": "",
// "username": {
// "regex": "^[\\p{L}\\p{M}' \\-]+$"
// }
//},
//"recaptcha": {
// "private-key": "6Leg06YUAAAAAKcKAVL8u_ZU4xbXAjPiAflBaA-2",
// "required": "true"
//},
//"web": {
// "api-cache": "",
// "app": {
// "keys": "ios-1e88-4c51-925c-6e521f2b2b46,android-39ed-4f49-89a4-01fe9175dc91"
// },
// "autotest": {
// "secret-email": "^teamlab.ruby@gmail.com$|^teamlab.hourly.check@gmail.com$|^teamlab.daily.check@gmail.com$|^.+@qamail.teamlab.info"
// }
//}
}