base.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:foreman-yml 作者: adfinis-sygroup 项目源码 文件源码
def connect(self):
        try:
            logging.disable(logging.WARNING)
            self.fm = Foreman(self.config['auth']['url'], (self.config['auth']['user'], self.config['auth']['pass']), api_version=2, use_cache=False, strict_cache=False)
            # this is nescesary for detecting faulty credentials in yaml
            self.fm.architectures.index()
            logging.disable(self.loglevel-1)
        except:
            log.log(log.LOG_ERROR, "Cannot connect to Foreman-API")
            sys.exit(1)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号