From 191e3036e1384efc3438487674a442e43503999a Mon Sep 17 00:00:00 2001 From: Amrith Kumar Date: Wed, 19 Apr 2017 10:15:36 -0400 Subject: [PATCH] fix-gate: change trove auth URL's to reflect new URL settings Trove's code was setup to use :5000 and :35357 for keystone's auth end points. Change that to reflect the new settings that are /identity/ and /identity_admin/. See also [1] [1] https://review.openstack.org/#/c/456344/ Change-Id: I3d6f6649430ee40879de15fee0b215dc32e8b666 Related: I46294fb24e3c23fa19fcfd7d6c9ee8a932354702 --- devstack/plugin.sh | 5 +++-- etc/trove/api-paste.ini.test | 2 +- etc/trove/trove-conductor.conf.sample | 2 +- etc/trove/trove-taskmanager.conf.sample | 4 ++-- etc/trove/trove.conf.sample | 4 ++-- etc/trove/trove.conf.test | 4 ++-- install-guide/source/common_configure.txt | 8 ++++---- integration/scripts/conf/test_begin.conf | 4 ++-- integration/scripts/trovestack | 2 +- integration/tests/examples/examples/local.conf | 2 +- trove/common/cfg.py | 2 +- trove/tests/config.py | 4 ++-- 12 files changed, 22 insertions(+), 21 deletions(-) diff --git a/devstack/plugin.sh b/devstack/plugin.sh index d29d73e308..b423ff27bc 100644 --- a/devstack/plugin.sh +++ b/devstack/plugin.sh @@ -160,6 +160,8 @@ function configure_trove { rm -f $TROVE_TASKMANAGER_CONF rm -f $TROVE_CONDUCTOR_CONF + TROVE_AUTH_ENDPOINT=$KEYSTONE_AUTH_URI/v$IDENTITY_API_VERSION + # (Re)create trove api conf file if needed if is_service_enabled tr-api; then # Set common configuration values (but only if they're defined) @@ -180,12 +182,11 @@ function configure_trove { iniset $TROVE_CONF DEFAULT trove_api_workers "$API_WORKERS" configure_auth_token_middleware $TROVE_CONF trove $TROVE_AUTH_CACHE_DIR + iniset $TROVE_CONF DEFAULT trove_auth_url $TROVE_AUTH_ENDPOINT fi # (Re)create trove taskmanager conf file if needed if is_service_enabled tr-tmgr; then - TROVE_AUTH_ENDPOINT=$KEYSTONE_AUTH_URI/v$IDENTITY_API_VERSION - # Use these values only if they're set iniset_conditional $TROVE_TASKMANAGER_CONF DEFAULT agent_call_low_timeout $TROVE_AGENT_CALL_LOW_TIMEOUT iniset_conditional $TROVE_TASKMANAGER_CONF DEFAULT agent_call_high_timeout $TROVE_AGENT_CALL_HIGH_TIMEOUT diff --git a/etc/trove/api-paste.ini.test b/etc/trove/api-paste.ini.test index f2b0bc083c..de24321a80 100644 --- a/etc/trove/api-paste.ini.test +++ b/etc/trove/api-paste.ini.test @@ -21,7 +21,7 @@ service_port = 5000 auth_host = 127.0.0.1 auth_port = 35357 auth_protocol = http -auth_uri = http://127.0.0.1:5000/ +auth_uri = http://127.0.0.1/identity/ signing_dir = /tmp/keystone-signing-trove [filter:authorization] diff --git a/etc/trove/trove-conductor.conf.sample b/etc/trove/trove-conductor.conf.sample index 964303ea84..8a1f82838e 100644 --- a/etc/trove/trove-conductor.conf.sample +++ b/etc/trove/trove-conductor.conf.sample @@ -1,6 +1,6 @@ [DEFAULT] debug = True -trove_auth_url = http://0.0.0.0:5000/v2.0 +trove_auth_url = http://0.0.0.0/identity/v2.0 # The manager class to use for conductor. (string value) conductor_manager = trove.conductor.manager.Manager diff --git a/etc/trove/trove-taskmanager.conf.sample b/etc/trove/trove-taskmanager.conf.sample index 69a64ff22b..03f619dcc4 100644 --- a/etc/trove/trove-taskmanager.conf.sample +++ b/etc/trove/trove-taskmanager.conf.sample @@ -27,7 +27,7 @@ control_exchange = trove db_api_implementation = trove.db.sqlalchemy.api # Configuration options for talking to nova via the novaclient. -trove_auth_url = http://0.0.0.0:5000/v2.0 +trove_auth_url = http://0.0.0.0/identity/v2.0 #nova_compute_url = http://localhost:8774/v2 #cinder_url = http://localhost:8776/v1 #swift_url = http://localhost:8080/v1/AUTH_ @@ -82,7 +82,7 @@ notification_service_id = mysql:2f3ff068-2bfb-4f70-9a9d-a6bb65bc084b # Trove DNS trove_dns_support = False dns_account_id = 123456 -dns_auth_url = http://127.0.0.1:5000/v2.0 +dns_auth_url = http://127.0.0.1/identity/v2.0 dns_username = user dns_passkey = password dns_ttl = 3600 diff --git a/etc/trove/trove.conf.sample b/etc/trove/trove.conf.sample index a64f752259..054d63bd62 100644 --- a/etc/trove/trove.conf.sample +++ b/etc/trove/trove.conf.sample @@ -37,7 +37,7 @@ control_exchange = trove db_api_implementation = "trove.db.sqlalchemy.api" # Configuration options for talking to nova via the novaclient. -trove_auth_url = http://0.0.0.0:5000/v2.0 +trove_auth_url = http://0.0.0.0/identity/v2.0 #nova_compute_url = http://localhost:8774/v2 #cinder_url = http://localhost:8776/v1 #swift_url = http://localhost:8080/v1/AUTH_ @@ -92,7 +92,7 @@ http_mgmt_post_rate = 200 # Trove DNS trove_dns_support = False dns_account_id = 123456 -dns_auth_url = http://127.0.0.1:5000/v2.0 +dns_auth_url = http://127.0.0.1/identity/v2.0 dns_username = user dns_passkey = password dns_ttl = 3600 diff --git a/etc/trove/trove.conf.test b/etc/trove/trove.conf.test index e22b4c0b12..65ef0a03c0 100644 --- a/etc/trove/trove.conf.test +++ b/etc/trove/trove.conf.test @@ -48,7 +48,7 @@ db_api_implementation = trove.db.sqlalchemy.api nova_proxy_admin_user = admin nova_proxy_admin_pass = 3de4922d8b6ac5a1aad9 nova_proxy_admin_tenant_id = -trove_auth_url = http://0.0.0.0:5000/v2.0 +trove_auth_url = http://0.0.0.0/identity/v2.0 os_region_name = RegionOne nova_compute_service_type = compute @@ -182,7 +182,7 @@ service_port = 5000 auth_host = 127.0.0.1 auth_port = 35357 auth_protocol = http -auth_uri = http://127.0.0.1:5000/ +auth_uri = http://127.0.0.1/identity/ [filter:authorization] paste.filter_factory = trove.common.auth:AuthorizationMiddleware.factory diff --git a/install-guide/source/common_configure.txt b/install-guide/source/common_configure.txt index e768daaf7c..e98154e3d4 100644 --- a/install-guide/source/common_configure.txt +++ b/install-guide/source/common_configure.txt @@ -8,7 +8,7 @@ [DEFAULT] log_dir = /var/log/trove - trove_auth_url = http://controller:5000/v2.0 + trove_auth_url = http://controller/identity/v2.0 nova_compute_url = http://controller:8774/v2 cinder_url = http://controller:8776/v1 swift_url = http://controller:8080/v1/AUTH_ @@ -53,8 +53,8 @@ ... [keystone_authtoken] ... - auth_uri = http://controller:5000 - auth_url = http://controller:35357 + auth_uri = http://controller/identity + auth_url = http://controller/identity_admin auth_type = password project_domain_name = default user_domain_name = default @@ -100,7 +100,7 @@ nova_proxy_admin_user = admin nova_proxy_admin_pass = ADMIN_PASS nova_proxy_admin_tenant_name = service - trove_auth_url = http://controller:35357/v2.0 + trove_auth_url = http://controller/identity_admin/v2.0 7. Populate the trove database you created earlier in this procedure: diff --git a/integration/scripts/conf/test_begin.conf b/integration/scripts/conf/test_begin.conf index eff96dea6f..0f526c5f29 100644 --- a/integration/scripts/conf/test_begin.conf +++ b/integration/scripts/conf/test_begin.conf @@ -1,14 +1,14 @@ { "dbaas_url":"http://%service_host%:8779/v1.0", "version_url":"http://%service_host%:8779", - "trove_auth_url":"http://%service_host%:35357/v2.0/tokens", + "trove_auth_url":"http://%service_host%/identity_admin/v2.0/tokens", "trove_client_insecure":false, "auth_strategy":null, "trove_client_region_name": "%region_name%", "nova_client": { "url":"http://%service_host%:8774/v1.1", - "auth_url":"http://%service_host%:35357/v2.0", + "auth_url":"http://%service_host%/identity_admin/v2.0", "nova_service_type":"compute", "volume_service_type":"volume" }, diff --git a/integration/scripts/trovestack b/integration/scripts/trovestack index 27a8bcaef7..8b1ba4ec9b 100755 --- a/integration/scripts/trovestack +++ b/integration/scripts/trovestack @@ -1061,7 +1061,7 @@ function cmd_example_tests() { echo " { \"directory\": \"$TROVESTACK_TESTS/../apidocs/src/resources/samples/\", - \"auth_url\":\"http://$KEYSTONE_AUTH_HOST:35357/v2.0/tokens\", + \"auth_url\":\"http://$KEYSTONE_AUTH_HOST/identity_admin/v2.0/tokens\", \"api_url\":\"http://$SERVICE_HOST:8779\", \"replace_host\":\"https://ord.databases.api.rackspacecloud.com\", \"replace_dns_hostname\": \"e09ad9a3f73309469cf1f43d11e79549caf9acf2.rackspaceclouddb.com\", diff --git a/integration/tests/examples/examples/local.conf b/integration/tests/examples/examples/local.conf index 682200da5a..dab1e153e5 100644 --- a/integration/tests/examples/examples/local.conf +++ b/integration/tests/examples/examples/local.conf @@ -1,6 +1,6 @@ { "directory": "/src/apidocs/src/resources/samples/", - "auth_url":"http://localhost:35357/v2.0/tokens", + "auth_url":"http://localhost/identity_admin/v2.0/tokens", "api_url":"http://localhost:8779", "replace_host":"https://ord.databases.api.rackspacecloud.com", "replace_dns_hostname": "e09ad9a3f73309469cf1f43d11e79549caf9acf2.rackspaceclouddb.com", diff --git a/trove/common/cfg.py b/trove/common/cfg.py index 7edc633a2d..eefe9e97b4 100644 --- a/trove/common/cfg.py +++ b/trove/common/cfg.py @@ -97,7 +97,7 @@ common_opts = [ help='Service type to use when searching catalog.'), cfg.StrOpt('glance_endpoint_type', default='publicURL', help='Service endpoint type to use when searching catalog.'), - cfg.URIOpt('trove_auth_url', default='http://0.0.0.0:5000/v2.0', + cfg.URIOpt('trove_auth_url', default='http://0.0.0.0/identity/v2.0', help='Trove authentication URL.'), cfg.StrOpt('trove_url', help='URL without the tenant segment.'), cfg.StrOpt('trove_service_type', default='database', diff --git a/trove/tests/config.py b/trove/tests/config.py index 4d92bc77d3..8aa489c8a2 100644 --- a/trove/tests/config.py +++ b/trove/tests/config.py @@ -66,8 +66,8 @@ class TestConfig(object): self._values = { 'clean_slate': os.environ.get("CLEAN_SLATE", "False") == "True", 'fake_mode': os.environ.get("FAKE_MODE", "False") == "True", - 'nova_auth_url': "http://localhost:5000/v2.0", - 'trove_auth_url': "http://localhost:5000/v2.0/tokens", + 'nova_auth_url': "http://localhost/identity/v2.0", + 'trove_auth_url': "http://localhost/identity/v2.0/tokens", 'dbaas_url': "http://localhost:8775/v1.0/dbaas", 'version_url': "http://localhost:8775/", 'nova_url': "http://localhost:8774/v2",