From 4bbd03210f82d8f9a89627e08a546ba9841ff7fb Mon Sep 17 00:00:00 2001 From: Dean Troyer Date: Fri, 8 Aug 2014 17:38:44 -0500 Subject: Change app.restapi to app.client_manager.session This is step 1 toward using Keystone client's session.Session as the primary session/requests interface in OSC. * Move the session create into ClientManager and rename 'restapi' attribute to 'session' * Set up ClientManager and session loggers * Fix container and object command references to restapi/api Change-Id: I013d81520b336c7a6422cd22c05d1d65655e64f8 --- openstackclient/identity/client.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'openstackclient/identity') diff --git a/openstackclient/identity/client.py b/openstackclient/identity/client.py index 7f5390c8..172910f5 100644 --- a/openstackclient/identity/client.py +++ b/openstackclient/identity/client.py @@ -66,7 +66,17 @@ def make_client(instance): insecure=instance._insecure, trust_id=instance._trust_id, ) + + # TODO(dtroyer): the identity v2 role commands use this yet, fix that + # so we can remove it instance.auth_ref = client.auth_ref + + # NOTE(dtroyer): this is hanging around until restapi is replace by + # ksc session + instance.session.set_auth( + client.auth_ref.auth_token, + ) + return client -- cgit v1.2.1