diff --git a/heat/common/heat_keystoneclient.py b/heat/common/heat_keystoneclient.py index 29a54488e1..b4d16e1446 100644 --- a/heat/common/heat_keystoneclient.py +++ b/heat/common/heat_keystoneclient.py @@ -151,12 +151,11 @@ class KeystoneClientV3(object): kwargs['trust_id'] = self.context.trust_id kwargs.pop('project_name') elif self.context.auth_token is not None: - kwargs['project_name'] = self.context.tenant kwargs['token'] = self.context.auth_token + kwargs['project_id'] = self.context.tenant_id elif self.context.password is not None: kwargs['username'] = self.context.username kwargs['password'] = self.context.password - kwargs['project_name'] = self.context.tenant kwargs['project_id'] = self.context.tenant_id else: logger.error(_("Keystone v3 API connection failed, no password " diff --git a/heat/tests/test_heatclient.py b/heat/tests/test_heatclient.py index 320f13c447..c1df650700 100644 --- a/heat/tests/test_heatclient.py +++ b/heat/tests/test_heatclient.py @@ -91,7 +91,7 @@ class KeystoneClientTest(HeatTestCase): if method == 'token': kc_v3.Client( - token='abcd1234', project_name='test_tenant', + token='abcd1234', project_id='test_tenant_id', auth_url='http://server.test:5000/v3', endpoint='http://server.test:5000/v3', cacert=None, @@ -102,7 +102,6 @@ class KeystoneClientTest(HeatTestCase): kc_v3.Client( username='test_username', password='password', - project_name='test_tenant', project_id='test_tenant_id', auth_url='http://server.test:5000/v3', endpoint='http://server.test:5000/v3',