master
admingit 3 years ago
parent c32a30f6c3
commit 45baa7c54c

@ -33,7 +33,25 @@
- /etc/systemd/system/Splunk.service - /etc/systemd/system/Splunk.service
- name: "Shutdown VM" - name: "Shutdown VM"
reboot: shell: shutdown -r now
reboot_timeout: 300
async: 0 - name: Wait for the reboot and reconnect
poll: 0 wait_for:
port: 22
search_regex: OpenSSH
delay: 10
timeout: 60
connection: local
- name: Check the Uptime of the servers
shell: "uptime"
register: Uptime
- debug: var=Uptime
#- name: "Shutdown VM"
#reboot:
#reboot_timeout: 300
#async: 0
#poll: 0

@ -31,9 +31,26 @@
with_items: with_items:
- /etc/init.d/splunk - /etc/init.d/splunk
- /etc/systemd/system/splunk.service - /etc/systemd/system/splunk.service
- name: "Shutdown VM" - name: "Shutdown VM"
reboot: shell: shutdown -r now
reboot_timeout: 300
async: 0 - name: Wait for the reboot and reconnect
poll: 0 wait_for:
port: 22
search_regex: OpenSSH
delay: 10
timeout: 60
connection: local
- name: Check the Uptime of the servers
shell: "uptime"
register: Uptime
- debug: var=Uptime
#- name: "Shutdown VM"
#reboot:
#reboot_timeout: 300
#async: 0
#poll: 0

Loading…
Cancel
Save