Ejemplo n.º 1
0
        public Startup(IConfiguration configuration, IHostingEnvironment env, CrmsStartupConfig startupConfig)
        {
            _hostingEnvironment = env;
            _startupConfig      = startupConfig;

            var builder = new ConfigurationBuilder()
                          .SetBasePath(env.ContentRootPath)
                          .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true)
                          .AddJsonFile($"appsettings.{env.EnvironmentName}.json", optional: true)
                          .AddEnvironmentVariables();

            _configuration = builder.Build();
        }
Ejemplo n.º 2
0
 public Startup(IConfiguration configuration, IHostingEnvironment env, CrmsStartupConfig startupConfig)
 {
     _hostingEnvironment = env;
     _startupConfig      = startupConfig;
     _configuration      = configuration;
 }