Switch ansible module command with copy
We thought there were a bug in copy command due the fact it wasn't copying the files to logs. Turns out it was the remote_src option that was missed. Change-Id: I1712959f68276162a6e8b6f0a10c80ff3ed94367
This commit is contained in:
parent
a175eb99b4
commit
6f471b6dd5
@ -4,17 +4,19 @@
|
|||||||
file:
|
file:
|
||||||
path: /tmp/logs/tempest
|
path: /tmp/logs/tempest
|
||||||
state: directory
|
state: directory
|
||||||
become: True
|
become: true
|
||||||
|
|
||||||
# Using command instead of copy due
|
|
||||||
# https://github.com/ansible/ansible/issues/42198
|
|
||||||
- name: Copying tempest logs and config to /tmp/logs/tempest
|
- name: Copying tempest logs and config to /tmp/logs/tempest
|
||||||
command: "sudo cp {{ item }} /tmp/logs/tempest"
|
copy:
|
||||||
|
src: "{{ item }}"
|
||||||
|
dest: /tmp/logs/tempest
|
||||||
|
remote_src: true
|
||||||
with_items:
|
with_items:
|
||||||
- /opt/stack/tempest/etc/tempest.conf
|
- /opt/stack/tempest/etc/tempest.conf
|
||||||
- /opt/stack/tempest/tempest.log
|
- /opt/stack/tempest/tempest.log
|
||||||
- /etc/openstack/accounts.yaml
|
- /etc/openstack/accounts.yaml
|
||||||
ignore_errors: True
|
ignore_errors: true
|
||||||
|
become: true
|
||||||
|
|
||||||
- name: Upload logs
|
- name: Upload logs
|
||||||
synchronize:
|
synchronize:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user