Merge "Fix error msg for wrong auth_url in functional"
This commit is contained in:
commit
e37e73e63d
@ -14,6 +14,7 @@ import os
|
|||||||
|
|
||||||
from ceilometerclient import client as ceilometer_client
|
from ceilometerclient import client as ceilometer_client
|
||||||
from cinderclient import client as cinder_client
|
from cinderclient import client as cinder_client
|
||||||
|
from heat.common.i18n import _
|
||||||
from heatclient import client as heat_client
|
from heatclient import client as heat_client
|
||||||
from keystoneclient.auth.identity.generic import password
|
from keystoneclient.auth.identity.generic import password
|
||||||
from keystoneclient import exceptions as kc_exceptions
|
from keystoneclient import exceptions as kc_exceptions
|
||||||
@ -71,8 +72,13 @@ class ClientManager(object):
|
|||||||
|
|
||||||
def __init__(self, conf):
|
def __init__(self, conf):
|
||||||
self.conf = conf
|
self.conf = conf
|
||||||
self.v2_auth_url = self.conf.auth_url.replace('/v3', '/v2.0')
|
if self.conf.auth_url.find('/v'):
|
||||||
self.auth_version = self.conf.auth_url.split('/v')[1]
|
self.v2_auth_url = self.conf.auth_url.replace('/v3', '/v2.0')
|
||||||
|
self.auth_version = self.conf.auth_url.split('/v')[1]
|
||||||
|
else:
|
||||||
|
raise ValueError(_('Incorrectly specified auth_url config: no '
|
||||||
|
'version found.'))
|
||||||
|
|
||||||
self.identity_client = self._get_identity_client()
|
self.identity_client = self._get_identity_client()
|
||||||
self.orchestration_client = self._get_orchestration_client()
|
self.orchestration_client = self._get_orchestration_client()
|
||||||
self.compute_client = self._get_compute_client()
|
self.compute_client = self._get_compute_client()
|
||||||
|
Loading…
Reference in New Issue
Block a user