Compare commits
No commits in common. "84a572af6820fe1fdf660dfbec375f69200e8fa6" and "65f681a35a604a3fe36672caa5cf7bcd334a0af1" have entirely different histories.
84a572af68
...
65f681a35a
@ -7,13 +7,10 @@ namespace YTExtractor.Data
|
||||
private readonly IMongoDatabase _database;
|
||||
private readonly IMongoCollection<VideoData> _collection;
|
||||
|
||||
public MongoDBConnector(IConfiguration configuration, Serilog.ILogger logger)
|
||||
public MongoDBConnector(IConfiguration configuration)
|
||||
{
|
||||
var connectionString = configuration.GetSection("MongoDbConnection").Value;
|
||||
var databaseName = configuration.GetSection("MongoDbDatabase").Value;
|
||||
|
||||
logger.Information($"ConnString: {connectionString}");
|
||||
logger.Information($"DbName: {databaseName}");
|
||||
var client = new MongoClient(connectionString);
|
||||
_database = client.GetDatabase(databaseName);
|
||||
_collection = _database.GetCollection<VideoData>("videos");
|
||||
|
||||
@ -26,5 +26,9 @@
|
||||
},
|
||||
"AllowedHosts": "*",
|
||||
"MongoDbConnection": "mongodb://admin:c4rn31r0@localhost:27017,localhost:27018/?authSource=admin",
|
||||
"MongoDbDatabase": "YTExtractor.Prod"
|
||||
"MongoDbDatabase": "YTExtractor.Prod",
|
||||
"YouExpose": {
|
||||
"ApiKey": "sua-chave-api-producao-aqui",
|
||||
"ApiUrl": "https://api.youexpose.com/"
|
||||
}
|
||||
}
|
||||
@ -20,5 +20,8 @@
|
||||
},
|
||||
"AllowedHosts": "*",
|
||||
"MongoDbConnection": "mongodb://admin:c4rn31r0@192.168.0.82:27017,192.168.0.81:27017/?replicaSet=rs0",
|
||||
"MongoDbDatabase": "YTExtractor"
|
||||
"YouExpose": {
|
||||
"ApiKey": "sua-chave-api-aqui",
|
||||
"ApiUrl": "https://api.youexpose.com/"
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user