not supporting V3 when fetching the Keystone ID being used as Cloud Provider ID

Bug #1495671 reported by Matthew Edmonds on 2015-09-14
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
refstack
Undecided
Unassigned

Bug Description

RefstackClient_get_cpid_from_keystone is assuming keystone v2.0, and will not work on keystone v3 setups. It imports the v2.0 client from keystoneclient and does not read in domain information from the conf.

(.venv)[root@myhost refstack-client]# ./refstack-client test -c ~/my_refstack.conf -vv -k
2015-09-14 15:02:58,740 refstack_client:116 DEBUG The .testrepository/next-stream file was not found. Assuming subunit results will be stored in file 0.
Traceback (most recent call last):
  File "./refstack-client", line 31, in <module>
    getattr(test, args.func)()
  File "/root/refstack-client/refstack_client/refstack_client.py", line 226, in test
    cpid = self._get_cpid_from_keystone(self.conf)
  File "/root/refstack-client/refstack_client/refstack_client.py", line 141, in _get_cpid_from_keystone
    client = ksclient.Client(**args)
  File "/root/refstack-client/.venv/lib/python2.7/site-packages/keystoneclient/v2_0/client.py", line 166, in __init__
    self.authenticate()
  File "/root/refstack-client/.venv/lib/python2.7/site-packages/keystoneclient/utils.py", line 337, in inner
    return func(*args, **kwargs)
  File "/root/refstack-client/.venv/lib/python2.7/site-packages/keystoneclient/httpclient.py", line 589, in authenticate
    resp = self.get_raw_token_from_identity_service(**kwargs)
  File "/root/refstack-client/.venv/lib/python2.7/site-packages/keystoneclient/v2_0/client.py", line 210, in get_raw_token_from_identity_service
    _("Authorization Failed: %s") % e)
keystoneclient.exceptions.AuthorizationFailure: Authorization Failed: The resource could not be found. (HTTP 404) (Request-ID: req-0c159858-1534-405d-ae8b-ecb6b77abb03)

from my_refstack.conf:

[identity]
catalog_type = identity
disable_ssl_certificate_validation = True
uri = https://127.0.0.1:5000/v3/auth/tokens
uri_v3 = https://127.0.0.1:5000/v3/auth/tokens
region = RegionOne
username = myuser
password = mypassword
tenant_name = myproject
alt_username = myuser
alt_password = mypassword
alt_tenant_name = myproject
admin_username = myuser
admin_password = mypassword
admin_tenant_name = myproject
admin_role = admin

description: updated
David Liu (lzbj) wrote :

reproduced, assign to myself try to fix it.

Changed in refstack:
assignee: nobody → david liu (lzbj)
status: New → In Progress
Matthew Edmonds (edmondsw) wrote :
Changed in refstack:
status: In Progress → Fix Committed
assignee: david liu (lzbj) → nobody
Catherine Diep (cdiep) on 2015-12-17
Changed in refstack:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers