Render zuul_api_url as python list

The logscraper tool gets zuul_api_url parameter as a list and
there can be multiple values provided.

Change-Id: I8356a6527214bf58201752146951b95912029309
This commit is contained in:
Daniel Pawlik 2023-02-07 21:29:04 +01:00
parent fff0191f98
commit 36f7f36bab
6 changed files with 15 additions and 11 deletions

View File

@ -5,8 +5,7 @@
# logscraper
tenant_builds:
- tenant: openstack
zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
zuul_api_urls:
zuul_api_url:
- https://zuul.opendev.org/api/tenant/openstack
insecure: false
job_names: []

View File

@ -17,8 +17,7 @@
- tenant: openstack
gearman_port: "{{ gearman_port }}"
gearman_server: "{{ gearman_host }}"
zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
zuul_api_urls:
zuul_api_url:
- https://zuul.opendev.org/api/tenant/openstack
insecure: false
job_names: []

View File

@ -6,7 +6,8 @@
# logscraper and logsender
tenant_builds:
- tenant: openstack
zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
zuul_api_url:
- https://zuul.opendev.org/api/tenant/openstack
download: true
download_dir: /mnt/logscraper/openstack
es_username: logstash

View File

@ -25,7 +25,8 @@ for example:
- tenant: openstack
gearman_port: 4731
gearman_server: logstash.openstack.org
zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
zuul_api_url:
- https://zuul.opendev.org/api/tenant/openstack
insecure: false
will deploy service with name: `logscraper@openstack.service`.
@ -57,10 +58,12 @@ and second one for getting logs from `sometenant` tenant.
- tenant: openstack
gearman_port: 4731
gearman_server: logstash.openstack.org
zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
zuul_api_url:
- https://zuul.opendev.org/api/tenant/openstack
insecure: False
- tenant: sometenant
zuul_api_url: https://zuul.opendev.org/api/tenant/sometenant
zuul_api_url:
- https://zuul.opendev.org/api/tenant/sometenant
insecure: True
download: true
download_dir: /mnt/logscraper

View File

@ -14,11 +14,13 @@ container_images:
# - tenant: openstack
# gearman_port: 4731
# gearman_server: logstash.openstack.org
# zuul_api_url: https://zuul.opendev.org/api/tenant/openstack
# zuul_api_url:
# - https://zuul.opendev.org/api/tenant/openstack
# insecure: false
# logscraper_workers: 1
# - tenant: sometenant
# zuul_api_url: https://zuul.opendev.org/api/tenant/sometenant
# zuul_api_url:
# - https://zuul.opendev.org/api/tenant/sometenant
# insecure: true
# download: true
# download_dir: /mnt/logscraper/sometenant

View File

@ -1,5 +1,5 @@
[DEFAULT]
zuul_api_url: {{ item['zuul_api_url'].split(', ') }}
zuul_api_url: {{ item['zuul_api_url'] | list }}
follow: {{ item['follow'] | default(true) }}
checkpoint_file: {{ item['checkpoint_file'] | default(logscraper_dir + '/checkpoint') }}
workers: {{ item['logscraper_workers'] | default(1) }}