summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlvaro Uría <alvaro.uria@canonical.com>2016-03-09 15:31:39 +0100
committerAlvaro Uría <alvaro.uria@canonical.com>2016-03-09 15:31:39 +0100
commit19f108508b32df8cb549b3a672ed60400157df95 (patch)
tree5a42252a47733b24b1ff67e7f1159001a111f33a
parent557b0e5cd242c922a735cd0a87d417c9b1c03677 (diff)
credentials() also returns "region" parameter
-rw-r--r--requires.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/requires.py b/requires.py
index 7828b3d..a7e5228 100644
--- a/requires.py
+++ b/requires.py
@@ -43,6 +43,15 @@ class KeystoneRequires(RelationBase):
43 def credentials(self): 43 def credentials(self):
44 """ 44 """
45 Returns a dict of keystone admin credentials 45 Returns a dict of keystone admin credentials
46
47 keystone provides:
48 {u'service_password': u'XXXXXXXX',
49 u'service_port': u'5000',
50 u'private-address': u'10.XX.XX.XXX',
51 u'service_hostname': u'10.XX.XX.XXX',
52 u'service_username': u'admin',
53 u'service_tenant_name': u'Admin',
54 u'service_region': u'RegionOne'}
46 """ 55 """
47 convs = self.conversations() 56 convs = self.conversations()
48 if len(convs) > 0: 57 if len(convs) > 0:
@@ -52,7 +61,8 @@ class KeystoneRequires(RelationBase):
52 'service_port': conv.get_remote('service_port'), 61 'service_port': conv.get_remote('service_port'),
53 'service_username': conv.get_remote('service_username'), 62 'service_username': conv.get_remote('service_username'),
54 'service_password': conv.get_remote('service_password'), 63 'service_password': conv.get_remote('service_password'),
55 'service_tenant_name': conv.get_remote('service_tenant_name') 64 'service_tenant_name': conv.get_remote('service_tenant_name'),
65 'service_region': conv.get_remote('service_region')
56 } 66 }
57 else: 67 else:
58 return {} 68 return {}