You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
353B

  1. ---
  2. - name: reboot
  3. command: shutdown -r 30
  4. async: 0
  5. poll: 0
  6. ignore_errors: true
  7. - name: wait for ssh
  8. local_action: wait_for host={{ ansible_host | default(inventory_hostname) }} port=22 search_regex=OpenSSH delay={{ reboot_delay }} timeout={{ reboot_timeout }} state=started
  9. - name: try to connect to ssh
  10. setup:
  11. retries: 10
  12. delay: 5