diff --git a/handlers/main.yml b/handlers/main.yml index b0f3137..0e51af6 100644 --- a/handlers/main.yml +++ b/handlers/main.yml @@ -18,12 +18,12 @@ - "host_reboot" - name: Wait for host - local_action: - module: wait_for - host={{ network_interfaces[network_defaultif].ipaddr }} - port=22 - delay=1 - timeout=300 + wait_for: + host: "{{ ansible_ssh_host }}" + port: 22 + delay: 5 + timeout: 300 + connection: local listen: - "network_restart" - "host_reboot"