change server reboot list
This commit is contained in:
@@ -21,7 +21,7 @@
|
||||
|
||||
- name: Get list of rebooted servers
|
||||
set_fact:
|
||||
rebooted_servers: "{{ ansible_play_hosts | select('in', reboot) }}"
|
||||
rebooted_servers: "{{ groups['all'] | intersect([host for host, result in reboot.items() if result.stat.exists]) }}"
|
||||
|
||||
- name: Debug rebooted servers
|
||||
debug:
|
||||
|
||||
Reference in New Issue
Block a user