summaryrefslogtreecommitdiff
path: root/openstackclient/common/clientmanager.py
diff options
context:
space:
mode:
authorSteve Martinelli <stevemar@ca.ibm.com>2015-06-11 02:43:57 -0400
committerSteve Martinelli <stevemar@ca.ibm.com>2015-06-11 02:43:57 -0400
commitaac0d588bd83b51cd2f4b36b22741497fb39d79f (patch)
treea53f03813e468c4405d19d7cbe67477ad36f6e97 /openstackclient/common/clientmanager.py
parentf3725b4761fb4cb6765a75d6cd2c861f5af99f1a (diff)
downloadpython-openstackclient-aac0d588bd83b51cd2f4b36b22741497fb39d79f.tar.gz
Skip trying to set project_domain_id if not using password
This is already fine for user_domain_id, and needs to be replicated for project_domain_id. Also added more logging. Change-Id: I3fa8f29edb3fc430d453bd0fc835312c0c8401f4
Diffstat (limited to 'openstackclient/common/clientmanager.py')
-rw-r--r--openstackclient/common/clientmanager.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/openstackclient/common/clientmanager.py b/openstackclient/common/clientmanager.py
index 6311c71a..0159ad7d 100644
--- a/openstackclient/common/clientmanager.py
+++ b/openstackclient/common/clientmanager.py
@@ -138,6 +138,7 @@ class ClientManager(object):
# present, then do not change the behaviour. Otherwise, set the
# PROJECT_DOMAIN_ID to 'OS_DEFAULT_DOMAIN' for better usability.
if (self._api_version.get('identity') == '3' and
+ self.auth_plugin_name.endswith('password') and
not self._auth_params.get('project_domain_id', None) and
not self.auth_plugin_name.startswith('v2') and
not self._auth_params.get('project_domain_name', None)):
@@ -160,6 +161,7 @@ class ClientManager(object):
self._project_name = self._auth_params['tenant_name']
LOG.info('Using auth plugin: %s' % self.auth_plugin_name)
+ LOG.debug('Using parameters %s' % self._auth_params)
self.auth = auth_plugin.load_from_options(**self._auth_params)
# needed by SAML authentication
request_session = requests.session()