log-inventory: add missing zuul_info_dir prep
The role can't be used as-is without zuul_info_dir fact. Change-Id: Id785f1b10e60dd09342edcebcbe7923b161add3c
This commit is contained in:
parent
fbb58ddfde
commit
8ed7cf4c52
@ -1,3 +1,10 @@
|
|||||||
Log the inventory used to run the job to the job's log dir.
|
Log the inventory used to run the job to the job's log dir.
|
||||||
|
|
||||||
This will result in the log collection roles logging the job inventory.
|
This will result in the log collection roles logging the job inventory.
|
||||||
|
|
||||||
|
**Role Variables**
|
||||||
|
|
||||||
|
.. zuul:rolevar:: zuul_info_dir
|
||||||
|
:default: {{ zuul.executor.log_root }}/zuul-info
|
||||||
|
|
||||||
|
The directory path to store the inventory file.
|
||||||
|
2
roles/log-inventory/defaults/main.yaml
Normal file
2
roles/log-inventory/defaults/main.yaml
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
---
|
||||||
|
zuul_info_dir: "{{ zuul.executor.log_root }}/zuul-info"
|
@ -1,3 +1,10 @@
|
|||||||
|
- name: Ensure Zuul Ansible directory exists
|
||||||
|
delegate_to: localhost
|
||||||
|
run_once: true
|
||||||
|
file:
|
||||||
|
path: "{{ zuul_info_dir }}"
|
||||||
|
state: directory
|
||||||
|
|
||||||
- name: Copy ansible inventory to logs dir
|
- name: Copy ansible inventory to logs dir
|
||||||
delegate_to: localhost
|
delegate_to: localhost
|
||||||
copy:
|
copy:
|
||||||
|
Loading…
Reference in New Issue
Block a user