From b399898b5785dfee18cdbe18687cb7a15a2f87c4 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Tue, 22 Sep 2015 11:29:46 -0500 Subject: Fix a little error with the None auth type Ironic has a mode where it does not use auth, but we still funnel that through the ksa admin_token type for consistency of code. The hack we had to do that went too far and caused validate_auth to strip the fake token we were adding. Change-Id: Id5275ac7db1a6052db02c2286cbf88862cb1ff70 --- os_client_config/config.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/os_client_config/config.py b/os_client_config/config.py index 1b6193e..fcca30a 100644 --- a/os_client_config/config.py +++ b/os_client_config/config.py @@ -419,7 +419,9 @@ class OpenStackConfig(object): # _other_ things (SSL arg handling, timeout) all work consistently if config['auth_type'] in (None, "None", ''): config['auth_type'] = 'admin_token' - config['auth']['token'] = None + # Set to notused rather than None because validate_auth will + # strip the value if it's actually python None + config['auth']['token'] = 'notused' return loading.get_plugin_loader(config['auth_type']) def _validate_auth_ksc(self, config): -- cgit v1.2.1