Fix bug with needs_restarting

This commit is contained in:
Jeffrey Serio 2023-03-27 15:51:54 -05:00
parent 2eb427c453
commit f8edb82302

View File

@ -31,6 +31,7 @@
register: needs_restarting
when: ansible_facts["os_family"] == "RedHat"
changed_when: needs_restarting.rc == 1
ignore_errors: true
- name: Reboot the machine (Wait for 5 min)
ansible.builtin.reboot:
@ -40,4 +41,3 @@
- needs_restarting.rc == 1
- ansible_facts["os_family"] == "RedHat"
ignore_errors: true
changed_when: needs_restarting == 1