From 02835b085608ba1fa88dd70e1fcf03c9b1801f29 Mon Sep 17 00:00:00 2001 From: Kiall Mac Innes Date: Sat, 25 May 2013 12:57:52 +0100 Subject: [PATCH] Always allow overriding the endpoint Change-Id: Iff4d152e8e59f895a42adf6927e559ca73472888 --- monikerclient/v1/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/monikerclient/v1/__init__.py b/monikerclient/v1/__init__.py index 67027fe..c02052a 100644 --- a/monikerclient/v1/__init__.py +++ b/monikerclient/v1/__init__.py @@ -41,7 +41,10 @@ class Client(object): auth = KeystoneAuth(auth_url, username, password, tenant_id, tenant_name, token, service_type, endpoint_type, sudo_tenant_id) - self.endpoint = auth.get_url() + if endpoint: + self.endpoint = endpoint + else: + self.endpoint = auth.get_url() elif endpoint: auth = None self.endpoint = endpoint