mirror of https://github.com/ansible/ansible.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
673 B
YAML
27 lines
673 B
YAML
6 years ago
|
---
|
||
|
- debug: msg="START connection={{ ansible_connection }} nxos_reboot sanity test"
|
||
|
- debug: msg="Using provider={{ connection.transport }}"
|
||
|
when: ansible_connection == "local"
|
||
|
|
||
|
- debug: msg="***WARNING*** Remove meta end_play to verify this module ***WARNING***"
|
||
|
|
||
|
- meta: end_play
|
||
|
|
||
|
- block:
|
||
|
- name: Reboot Switch
|
||
|
nxos_reboot:
|
||
|
confirm: True
|
||
|
provider: "{{ connection }}"
|
||
|
ignore_errors: yes
|
||
|
|
||
|
always:
|
||
|
- name: Wait for device to come back up
|
||
|
wait_for:
|
||
|
port: 22
|
||
|
state: started
|
||
|
timeout: 600
|
||
|
delay: 60
|
||
|
host: "{{ inventory_hostname }}"
|
||
|
|
||
|
- debug: msg="END connection={{ ansible_connection }} nxos_reboot sanity test"
|