Ejemplo n.º 1
0
        public Startup(IHostingEnvironment env)
        {
            var builder = new ConfigurationBuilder()
                          .SetBasePath(env.ContentRootPath)
                          .AddJsonFile("appsettings.json");

            _configuration = builder.Build();

            ConfiguretionModel.addConfig("RSAKey", _configuration.GetValue <String>("RSAKey"));
            ConfiguretionModel.addConfig("MongoDBString", _configuration.GetValue <String>("MongoDBString"));
        }
 public Databaseconfirmation()
 {
     _client   = new MongoClient(ConfiguretionModel.getConfig("MongoDBString"));
     _database = _client.GetDatabase("migration");
 }