Skip to content

Commit

Permalink
fix the dh_depoly_vm failure for Linux with power-on after rebase on v…
Browse files Browse the repository at this point in the history
…mware#489

Signed-off-by: linhuali <lli@vmware.com>
  • Loading branch information
linhuali committed Jan 30, 2024
1 parent d361621 commit 2e5c8a2
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion desktop_hypervisor/linux/dh_deploy_vm/deploy_vm_from_iso.yml
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,24 @@
vm_wait_log_delay: 30
vm_wait_log_retries: 120

- name: "Wait 60s for OS rebooting"
- name: "Get VM existence status"
include_tasks: ../../common/dh_host_check_vm_exists.yml
- name: "Set fact of VM existence status"
ansible.builtin.set_fact:
dh_vm_exists: "{{ dh_vm_check_exist }}"
- name: "Power on VM"
when: not dh_vm_exists
include_tasks: ../../common/dh_host_power_vm.yml
vars:
vm_power_option: "start"
- name: "Reset guest OS"
when: dh_vm_exists
include_tasks: ../../common/dh_host_power_vm.yml
vars:
vm_power_option: "reset"
vmrun_extra_option: "hard"

- name: "Wait 60s for OS powered on"
ansible.builtin.pause:
seconds: 60

Expand Down

0 comments on commit 2e5c8a2

Please sign in to comment.