ansible/reboot-prod.yml
2021-02-23 04:11:07 -06:00

14 lines
299 B
YAML
Executable File

#!/usr/bin/env ansible-playbook
# vim:ft=ansible:
---
- hosts: prod
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 or reboot_force
become: yes