def __init__(self, conf):
# novaclient only support keystone v3
auth_url = conf.read_option('keystone_authtoken',
'auth_url')
if auth_url.endswith('/v3'):
auth_url = auth_url.replace('/v3', '/v2.0')
self.nv_client = nova_client.Client(2,
conf.read_option(
'keystone_authtoken',
'username'),
conf.read_option(
'keystone_authtoken',
'password'),
conf.read_option(
'keystone_authtoken',
'project_name'),
auth_url,
region_name=conf.read_option(
'keystone_authtoken',
'region_name')
)
评论列表
文章目录