mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
fix bug where nova driver exits with no adminPass
This commit is contained in:
parent
3652dbae76
commit
1b98f7af38
2 changed files with 4 additions and 1 deletions
|
@ -633,6 +633,9 @@ def request_instance(vm_=None, call=None):
|
|||
vm_['name'], exc
|
||||
)
|
||||
)
|
||||
if data.extra.get('password', None) is None and vm_.get('key_filename', None) is None:
|
||||
raise SaltCloudSystemExit('No password returned. Set ssh_key_file.')
|
||||
|
||||
vm_['password'] = data.extra.get('password', '')
|
||||
|
||||
return data, vm_
|
||||
|
|
|
@ -336,7 +336,7 @@ class SaltNova(OpenStackComputeShell):
|
|||
)
|
||||
response = nt_ks.servers.create(**kwargs)
|
||||
self.uuid = response.id
|
||||
self.password = response.adminPass
|
||||
self.password = getattr(response, 'adminPass', None)
|
||||
|
||||
start = time.time()
|
||||
trycount = 0
|
||||
|
|
Loading…
Add table
Reference in a new issue