Use shell instead of command
We are having issues with collect-logs and potentially infra. Use shell so we get better output. This was motivated by a failure in collect-logs. https://ci.centos.org/job/tripleo-quickstart-promote-master-delorean-minimal/858/console failed here: https://github.com/openstack/tripleo-quickstart-extras/blame/master/roles/collect-logs/tasks/publish.yml#L23 The output from command module looks like this: 01:24:17.955 fatal: [localhost]: FAILED! => {"ansible_job_id": "897063162915.10850", "changed": false, "cmd": "/home/rdo-ci/.ansible/tmp/ansible-tmp-1484081443.92-162620171328073/command.py", "failed": 1, "finished": 1, "msg": "[Errno 2] No such file or directory", "outdata": "", "stderr": ""} The actual command is buried in {longpath}/command.py, and for the CI jobs only a handful of folks can get ssh access to the nodes, which would allow for setting ANSIBLE_KEEP_REMOTE_FILES=1 to debug this (by looking at the actual command.py after failure). Switching to shell block will output the expanded shell command to the output by default. Change-Id: Ie94492f023a2c7af8b6361f9538184c7de55cd7a
This commit is contained in:
parent
1529ce0ab9
commit
7b3d0b6aca
|
@ -10,7 +10,7 @@
|
|||
when: lookup('env', 'BUILD_URL') != ""
|
||||
|
||||
- name: upload to the artifact server using pubkey auth
|
||||
command: rsync -av --quiet -e "ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" {{ artcl_collect_dir }}/ {{ artcl_rsync_path }}/{{ lookup('env', 'BUILD_TAG') }}
|
||||
shell: rsync -av --quiet -e "ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" {{ artcl_collect_dir }}/ {{ artcl_rsync_path }}/{{ lookup('env', 'BUILD_TAG') }}
|
||||
async: "{{ artcl_publish_timeout }}"
|
||||
poll: 15
|
||||
retries: 5
|
||||
|
@ -20,7 +20,7 @@
|
|||
- name: upload to the artifact server using password auth
|
||||
environment:
|
||||
RSYNC_PASSWORD: "{{ lookup('env', 'RSYNC_PASSWORD') }}"
|
||||
command: rsync -av --quiet {{ artcl_collect_dir }}/ {{ artcl_rsync_path }}/{{ lookup('env', 'BUILD_TAG') }}
|
||||
shell: rsync -av --quiet {{ artcl_collect_dir }}/ {{ artcl_rsync_path }}/{{ lookup('env', 'BUILD_TAG') }}
|
||||
async: "{{ artcl_publish_timeout }}"
|
||||
poll: 15
|
||||
retries: 5
|
||||
|
@ -42,7 +42,7 @@
|
|||
when: artcl_use_swift|bool
|
||||
|
||||
- name: use zuul_swift_upload.py to publish the files
|
||||
command: "{{ artcl_zuul_swift_upload_path }}/zuul_swift_upload.py --name {{ artcl_swift_container }} --delete-after {{ artcl_swift_delete_after }} {{ artcl_collect_dir }}"
|
||||
shell: "{{ artcl_zuul_swift_upload_path }}/zuul_swift_upload.py --name {{ artcl_swift_container }} --delete-after {{ artcl_swift_delete_after }} {{ artcl_collect_dir }}"
|
||||
async: "{{ artcl_publish_timeout }}"
|
||||
poll: 15
|
||||
when: artcl_use_zuul_swift_upload|bool
|
||||
|
|
Loading…
Reference in New Issue