Set task status correctly for vmware_guest shutdown and reboot. (#26515)

pull/28669/head
Andrew Makousky 7 years ago committed by ansibot
parent 443b25d72a
commit 9190598096

@ -572,6 +572,9 @@ class PyVmomiHelper(object):
task = vm.ShutdownGuest()
else:
task = vm.RebootGuest()
# Set result['changed'] immediately because
# shutdown and reboot return None.
result['changed'] = True
else:
result['failed'] = True
result['msg'] = "VM %s must be in poweredon state & tools should be installed for guest shutdown/reboot" % vm.name

Loading…
Cancel
Save