Add automatic reboots to main playbook
This commit is contained in:
parent
90da5ad3b1
commit
a7aa38a8e9
13
playbooks/tags_autoreboot.yml
Executable file
13
playbooks/tags_autoreboot.yml
Executable file
@ -0,0 +1,13 @@
|
||||
#!/usr/bin/env ansible-playbook
|
||||
# vim:ft=ansible:
|
||||
---
|
||||
- hosts: tags_autoreboot
|
||||
serial: 1
|
||||
tasks:
|
||||
- name: check for reboot-required
|
||||
stat: path=/var/run/reboot-required
|
||||
register: s
|
||||
- name: reboot
|
||||
reboot: reboot_timeout=300
|
||||
when: s.stat.exists
|
||||
become: yes
|
Loading…
Reference in New Issue
Block a user