GoogleStorage.py 文件源码

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

项目:chirribackup 作者: killabytenow 项目源码 文件源码
def __init__(self, ldb, config = False):
        super(GoogleStorage, self).__init__(ldb, config)
        if not config:
            # okay .. not in config (ask_config() method)
            # load credentials and authenticate
            self.scopes = ['https://www.googleapis.com/auth/devstorage.read_write']
            self.credentials = ServiceAccountCredentials.from_json_keyfile_name(
                                    self.ldb.sm_gs_json_creds_file,
                                    scopes=self.scopes)
            self.service = discovery.build('storage', 'v1', credentials=self.credentials)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号