4689a7d938
If the job stops before the required directories here are created we get a failure copying, which stops us collecting things that may be useful to diagnosing the error. Put the copying in a block that ignores errors. Also just copy the /var/log/syslog -- I think this came in originally from something running on CentOS which doesn't have this, but now we run on Ubuntu hosts and syslog has interesting things for diagnosing errors. Change-Id: Iaca4801a652ef4a67772c804271ea5c1db377051
41 lines
1.2 KiB
YAML
41 lines
1.2 KiB
YAML
- hosts: all
|
|
roles:
|
|
- collect-container-logs
|
|
tasks:
|
|
- name: Copy nodepool logs
|
|
ignore_errors: yes
|
|
block:
|
|
- name: Copy nodepool log files
|
|
synchronize:
|
|
src: /var/log/nodepool
|
|
dest: '{{ zuul.executor.log_root }}'
|
|
mode: pull
|
|
- name: Copy nodepool config files
|
|
synchronize:
|
|
src: /etc/nodepool
|
|
dest: '{{ zuul.executor.log_root }}'
|
|
mode: pull
|
|
- name: Copy instance console logs
|
|
become: true
|
|
synchronize:
|
|
src: /opt/stack/data/nova/instances
|
|
dest: '{{ zuul.executor.log_root }}'
|
|
mode: pull
|
|
rsync_opts:
|
|
- "--include=*/"
|
|
- "--include=console.log"
|
|
- "--exclude=*"
|
|
- name: Copy syslog
|
|
become: True
|
|
synchronize:
|
|
src: "/var/log/syslog"
|
|
dest: '{{ zuul.executor.log_root }}'
|
|
mode: pull
|
|
|
|
- name: Copy docker logs
|
|
become: True
|
|
synchronize:
|
|
src: '{{ ansible_user_dir }}/zuul-output/logs/docker'
|
|
dest: '{{ zuul.executor.log_root }}'
|
|
mode: pull
|