Fix config_tempest failing due to v3 on ocata

The patch fixes config_tempest which was failing on RDO ocata installed by
packstack because of keystone v3 conflicts.

Change-Id: I4ff7cbc1cc11a892d870b146a280e6bdfbeeaba9
This commit is contained in:
Martin Kopec 2017-01-24 14:52:38 +00:00
parent 25e0580394
commit 00b1a51bd6
2 changed files with 3 additions and 3 deletions

View File

@ -202,7 +202,7 @@ def discover(auth_provider, region, object_store_discovery=True,
disable_ssl_certificate_validation)
if name == 'object-store' and not object_store_discovery:
services[name]['extensions'] = []
else:
elif 'v3' not in ep['publicURL']: # is not v3 url
services[name]['extensions'] = service.get_extensions()
services[name]['versions'] = service.get_versions()
return services

View File

@ -786,12 +786,12 @@ def configure_discovered_services(conf, services):
keystone_v3_support = conf.get('identity-feature-enabled', 'api_v3')
for service, ext_key in SERVICE_EXTENSION_KEY.iteritems():
if service in services:
extensions = ','.join(services[service]['extensions'])
extensions = ','.join(services[service].get('extensions', ""))
if service == 'object-store':
# tempest.conf is inconsistent and uses 'object-store' for the
# catalog name but 'object-storage-feature-enabled'
service = 'object-storage'
if service == 'identity' and keystone_v3_support:
elif service == 'identity' and keystone_v3_support:
identity_v3_ext = api_discovery.get_identity_v3_extensions(
conf.get("identity", "uri_v3"))
extensions = list(set(extensions.split(',') + identity_v3_ext))