summaryrefslogtreecommitdiff
path: root/openstackclient/shell.py
diff options
context:
space:
mode:
authorDean Troyer <dtroyer@gmail.com>2016-08-29 11:07:49 -0500
committerDean Troyer <dtroyer@gmail.com>2016-08-29 11:58:49 -0500
commitbec206fa0a0214d856259661c5e32086f33d2f62 (patch)
treeb03c9dfe24b8bde7f0667e572b09625f3249b8b0 /openstackclient/shell.py
parenta08b62523fa634d5a61d85d1e9f3b89ab2d4a14e (diff)
downloadpython-openstackclient-bec206fa0a0214d856259661c5e32086f33d2f62.tar.gz
Fix auth prompt brokenness
We start by fixing this in the already-present OSC_Config class so OSC can move forward. This change needs to get ported down into os-client-config in the near future, maybe even soon enough to make the client library freeze this week. * Add the pw-func argument to the OSC_Config (or OpenStackConfig) __init__() * When looping through the auth options from the KSA plugin look for any that have a prompt defined and do not have a value already, so ask for one. Closes-bug: #1617384 Change-Id: Ic86d56b8a6844516292fb74513712b486fec4442
Diffstat (limited to 'openstackclient/shell.py')
-rw-r--r--openstackclient/shell.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/openstackclient/shell.py b/openstackclient/shell.py
index da58b63b..26147be9 100644
--- a/openstackclient/shell.py
+++ b/openstackclient/shell.py
@@ -145,6 +145,7 @@ class OpenStackShell(shell.OpenStackShell):
'interface': None,
'auth_type': self._auth_type,
},
+ pw_func=shell.prompt_for_password,
)
except (IOError, OSError) as e:
self.log.critical("Could not read clouds.yaml configuration file")
@@ -162,7 +163,6 @@ class OpenStackShell(shell.OpenStackShell):
self.client_manager = clientmanager.ClientManager(
cli_options=self.cloud,
api_version=self.api_version,
- pw_func=shell.prompt_for_password,
)