provider.py 文件源码

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

项目:kozinaki 作者: compunova 项目源码 文件源码
def load_config(self):
        """Load config options from nova config file or command line (for example: /etc/nova/nova.conf)

        Sample settings in nova config:
            [kozinaki_EC2]
            user=AKIAJR7NAEIZPWSTFBEQ
            key=zv9zSem8OE+k/axFkPCgZ3z3tLrhvFBaIIa0Ik0j
        """

        provider_opts = [
            cfg.StrOpt('path_to_json_token', help='Google API json token file', secret=True),
            cfg.StrOpt('project', help='Google project id'),
            cfg.StrOpt('zone', help='Google zone name'),
        ]

        cfg.CONF.register_opts(provider_opts, self.config_name)
        return cfg.CONF[self.config_name]
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号