def __init_mongos(self, params): cfg = params.copy() log_path = cfg.setdefault( 'logpath', os.path.join(orchestration_mkdtemp(prefix='mongo-'), 'mongos.log')) self.__init_logpath(log_path) # use keyFile if self.auth_key: cfg['keyFile'] = self.key_file if 'port' not in cfg: cfg['port'] = process.PortPool().port(check=True) self.__init_test_commands(cfg) return process.write_config(cfg), cfg
def __init_mongos(self, params): cfg = params.copy() log_path = cfg.setdefault( 'logpath', os.path.join(orchestration_mkdtemp(prefix='mongo-'), 'mongos.log')) self.__init_logpath(log_path) # use keyFile if self.auth_key: cfg['keyFile'] = self.key_file if 'port' not in cfg: cfg['port'] = process.PortPool().port(check=True) self.__init_test_commands(cfg) return process.write_config(cfg), cfg
def __init_db(self, dbpath): if not dbpath: dbpath = orchestration_mkdtemp(prefix="mongo-") if not os.path.exists(dbpath): os.makedirs(dbpath) return dbpath
def __init_db(self, dbpath): if not dbpath: dbpath = orchestration_mkdtemp(prefix="mongo-") if not os.path.exists(dbpath): os.makedirs(dbpath) return dbpath