Merge "Fixed issue with waiting for ssh of deleted cluster"

This commit is contained in:
Jenkins 2015-04-02 20:19:17 +00:00 committed by Gerrit Code Review
commit b85cc4691b

View File

@ -108,6 +108,8 @@ class Engine(object):
'wait_until_accessible', _("Wait for instance accessibility"), 'wait_until_accessible', _("Wait for instance accessibility"),
sleep=5) sleep=5)
def _is_accessible(self, instance): def _is_accessible(self, instance):
if not g.check_cluster_exists(instance.cluster):
return True
try: try:
# check if ssh is accessible and cloud-init # check if ssh is accessible and cloud-init
# script is finished generating authorized_keys # script is finished generating authorized_keys
@ -126,8 +128,6 @@ class Engine(object):
mgmt_ip=instance.management_ip, reason=ex)) mgmt_ip=instance.management_ip, reason=ex))
return False return False
if not g.check_cluster_exists(instance.cluster):
return True
return False return False
@cpo.event_wrapper(mark_successful_on_exit=True) @cpo.event_wrapper(mark_successful_on_exit=True)