- action: shell echo "{{ item }}"
with_items:
- " /etc/* | fileglob"
register: task
tags:
- globtest
- debug: msg="{{item.item}}"
with_items: task.results
when: item.changed == True
tags:
- globtest
TASK: [common | shell echo ""] ************************************************
changed: [tlcav117] => (item= /etc/* | fileglob)
TASK: [common | debug msg="{{item.item}}"] ************************************
ok: [tlcav117] => (item={'item': ' /etc/* | fileglob', u'delta': u'0:00:00.002148', u'cmd': u'echo " /etc/* | fileglob" ', u'end': u'2013-11-22 23:44:54.216654', u'stderr': u'', u'stdout': u' /etc/* | fileglob', 'invocation': {'module_name': 'shell', 'module_args': u'echo " /etc/* | fileglob"'}, u'changed': True, u'rc': 0, u'start': u'2013-11-22 23:44:54.214506'}) => {
"item": {
"changed": true,
"cmd": "echo \" /etc/* | fileglob\" ",
"delta": "0:00:00.002148",
"end": "2013-11-22 23:44:54.216654",
"invocation": {
"module_args": "echo \" /etc/* | fileglob\"",
"module_name": "shell"
},
"item": " /etc/* | fileglob",
"rc": 0,
"start": "2013-11-22 23:44:54.214506",
"stderr": "",
"stdout": " /etc/* | fileglob"
},
"msg": " /etc/* | fileglob"
}