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('aws_secret_access_key', help='AWS secret key', secret=True),
cfg.StrOpt('aws_access_key_id', help='AWS access key id', secret=True),
cfg.StrOpt('region', help='AWS region name'),
]
cfg.CONF.register_opts(provider_opts, self.config_name)
return cfg.CONF[self.config_name]
评论列表
文章目录