blob: 625a8af34d9db46d3341d5036be24a12d6959c8f (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
- name: Reboot
ansible.builtin.reboot:
args:
# 3 minutes is plenty.
reboot_timeout: 180
# Don't reboot yourself accidentally:
when: 'ansible_env["SSH_CLIENT"].split()[0] not in ansible_all_ipv4_addresses'
become: true
listen: reboot
- name: Wait for connectivity
ansible.builtin.wait_for_connection:
args:
# 3 minutes is plenty.
timeout: 180
listen: reboot
|