Add collect and upload log roles
Change-Id: Id12fb552f81e7eda9992694250582823be2c1a3c
This commit is contained in:
parent
2f4e7ddaee
commit
47c850f0e3
|
@ -0,0 +1,6 @@
|
|||
- name: Collect logs from remote hosts.
|
||||
synchronize:
|
||||
dest: "{{ zuul.executor.log_root }}"
|
||||
mode: pull
|
||||
src: "logs/"
|
||||
no_log: true
|
|
@ -0,0 +1,15 @@
|
|||
- name: Set log path for a change.
|
||||
when: zuul.change
|
||||
set_fact:
|
||||
log_path: "{{ zuul.change[:-2] }}/{{ zuul.change }}/{{ zuul.patchset }}/{{ zuul.pipeline }}/{{ zuul.uuid[:7] }}/"
|
||||
|
||||
- name: Set log path for a ref update.
|
||||
when: zuul.newrev
|
||||
set_fact:
|
||||
log_path: "{{ zuul.newrev[:-2] }}/{{ zuul.newrev }}/{{ zuul.pipeline }}/{{ zuul.uuid[:7] }}/"
|
||||
|
||||
- name: Upload logs to log server.
|
||||
synchronize:
|
||||
src: "{{ zuul.executor.log_root }}"
|
||||
dest: "{{ log_path }}"
|
||||
no_log: true
|
Loading…
Reference in New Issue