more involved - temp check

This commit is contained in:
Seth Vidal 2012-11-21 18:45:20 +00:00
parent 4a7507ac6c
commit 3f95c45229

View file

@ -30,9 +30,13 @@
tasks:
- name: echo-y
action: command echo "I would run halt -p"
ignore_errors: true
# if one of them is down we don't care
- name: wait for them to die
local_action: wait_for port=23 delay=30 timeout=300 state=stopped host=$item
with_items: ${vmlist.list_vms}
- name: pause for 30s to let them die
local_action: pause seconds=30
- name: reboot vhost
hosts: $vhost
@ -40,4 +44,15 @@
tasks:
- name: echo what I would do
action: command echo 'I would run halt -r"
action: command echo 'I would run halt -r'
- name: wait for vhost to be back
local_action: wait_for host=$vhost port=22 delay=120 timeout=420
- name: check out vms again
action: virt command=list_vms
register: newvmlist
- name: should match
action: fail msg="Not all vms listed on system returned to the same state" rc=100
only_if: "$vmlist' != '$newvmlist'