Only create swift account if swift enabled

Only call the swift account creation function if swift is enabled,
otherwise the endpoints are created in keystone even though swift
isn't running.

This causes failures when tempest queries keystone and thinks swift is
there; it starts running tests against it that fail with unhelpful
"connection refused" errors.

Change-Id: Icf08409c9443ec703e5f1da4531aa34c326f3642
This commit is contained in:
Ian Wienand 2013-07-17 16:30:19 +10:00
parent 7ad51b4a47
commit 0ff314c01d

View File

@ -878,10 +878,13 @@ if is_service_enabled key; then
export OS_SERVICE_ENDPOINT=$SERVICE_ENDPOINT
create_keystone_accounts
create_nova_accounts
create_swift_accounts
create_cinder_accounts
create_neutron_accounts
if is_service_enabled swift || is_service_enabled s-proxy; then
create_swift_accounts
fi
# ``keystone_data.sh`` creates services, admin and demo users, and roles.
ADMIN_PASSWORD=$ADMIN_PASSWORD SERVICE_TENANT_NAME=$SERVICE_TENANT_NAME SERVICE_PASSWORD=$SERVICE_PASSWORD \
SERVICE_TOKEN=$SERVICE_TOKEN SERVICE_ENDPOINT=$SERVICE_ENDPOINT SERVICE_HOST=$SERVICE_HOST \