use archive instead of command

pull/2458/head
Cyril Jouve 2018-03-12 19:59:22 +01:00
parent 3a714fd4ac
commit 6abe78ff46
1 changed files with 6 additions and 1 deletions

View File

@ -114,7 +114,12 @@
with_items: "{{logs}}" with_items: "{{logs}}"
- name: Pack results and logs - name: Pack results and logs
local_action: raw GZIP=-9 tar --remove-files -cvzf {{dir|default(".")}}/logs.tar.gz -C /tmp collect-info archive:
path: "/tmp/collect-info"
dest: "{{ dir|default('.') }}/logs.tar.gz"
remove: true
delegate_to: localhost
become: false
run_once: true run_once: true
- name: Clean up collected command outputs - name: Clean up collected command outputs