[fix] credentials() handles all conversations
This commit is contained in:
parent
c37a179369
commit
557b0e5cd2
20
requires.py
20
requires.py
|
@ -44,14 +44,18 @@ class KeystoneRequires(RelationBase):
|
||||||
"""
|
"""
|
||||||
Returns a dict of keystone admin credentials
|
Returns a dict of keystone admin credentials
|
||||||
"""
|
"""
|
||||||
conv = self.conversation()
|
convs = self.conversations()
|
||||||
return {
|
if len(convs) > 0:
|
||||||
'service_hostname': conv.get_remote('service_hostname'),
|
conv = convs[0]
|
||||||
'service_port': conv.get_remote('service_port'),
|
return {
|
||||||
'service_username': conv.get_remote('service_username'),
|
'service_hostname': conv.get_remote('service_hostname'),
|
||||||
'service_password': conv.get_remote('service_password'),
|
'service_port': conv.get_remote('service_port'),
|
||||||
'service_tenant_name': conv.get_remote('service_tenant_name')
|
'service_username': conv.get_remote('service_username'),
|
||||||
}
|
'service_password': conv.get_remote('service_password'),
|
||||||
|
'service_tenant_name': conv.get_remote('service_tenant_name')
|
||||||
|
}
|
||||||
|
else:
|
||||||
|
return {}
|
||||||
|
|
||||||
def auth_data_complete(self):
|
def auth_data_complete(self):
|
||||||
data = self.credentials()
|
data = self.credentials()
|
||||||
|
|
Loading…
Reference in New Issue