Hi ansible users,

I have a playbook to reboot all my servers serially, using the "serial: 1" 
option in the playbook. I have the tasks:

- command: /sbin/reboot
- local_action: wait_for host={{inventory_hostname}} port=22 state=stopped

- local_action: wait_for host={{inventory_hostname}} port=22

However, some of my managed servers are not directly reachable from my 
laptop, so I usually connect to them via a bastion host. This means that 
the port 22 test will fail for them.

I thought about using the ping module instead, which should just do an SSH 
ping to a host. However, the ping module times out after a while when the 
underlying ssh connection times out, so I can't make it wait long enough 
for the server to finish rebooting.

Does anyone have any ideas or suggestions on how to work around this?

Anand

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to