From f96df6a048f8bab1207ef9efc783e2296e9efbe6 Mon Sep 17 00:00:00 2001 From: Jan Kaluza Date: Mon, 7 Dec 2020 08:42:03 +0100 Subject: [PATCH] ODCS: Add compose_ci source to test possible compose-ci packages gating. The idea is that we will start minimal compose for every new Koji build for package which appears in the boot.iso and therefore can break its generation. These composes will be built using ODCS on releng backend for now. Signed-off-by: Jan Kaluza --- inventory/group_vars/odcs | 4 ++ .../custom_compose_raw_config_wrapper.conf | 40 +++++++++++++++++++ roles/odcs/base/tasks/main.yml | 13 ++++++ 3 files changed, 57 insertions(+) create mode 100644 roles/odcs/base/files/odcs/custom_compose_raw_config_wrapper.conf diff --git a/inventory/group_vars/odcs b/inventory/group_vars/odcs index e0764f7e89..f027d7ab82 100644 --- a/inventory/group_vars/odcs +++ b/inventory/group_vars/odcs @@ -15,6 +15,10 @@ odcs_raw_config_urls: cccc: url: https://pagure.io/fedora-ci/cccc-merged-configs.git config_filename: cccc.conf + releng_compose_ci: + url: https://pagure.io/fedora-ci/compose-ci-pipeline.git + config_filename: compose_ci.conf + raw_config_wrapper: /etc/odcs/custom_compose_raw_config_wrapper.conf # Default queues for general ODCS backends. odcs_celery_queues: diff --git a/roles/odcs/base/files/odcs/custom_compose_raw_config_wrapper.conf b/roles/odcs/base/files/odcs/custom_compose_raw_config_wrapper.conf new file mode 100644 index 0000000000..8b5c884a5f --- /dev/null +++ b/roles/odcs/base/files/odcs/custom_compose_raw_config_wrapper.conf @@ -0,0 +1,40 @@ +# Wrapper config for real raw config file. +# The goal of this wrapper is to ensure that certain config options cannot be +# changed by the submitted raw config. +# This Raw Config wrapper allows overriding certain raw config configuration +# options. + +from raw_config import * + +koji_profile = 'odcs_production' +link_type = 'symlink' + + +createrepo_deltas = False + +dogpile_cache_backend = "dogpile.cache.dbm" +dogpile_cache_arguments = { + "filename": "/var/tmp/pungi_cache_file.dbm", +} +dogpile_cache_expiration_time = 14400 + +buildinstall_use_guestmount = True + + +# Allow overriding pkgset_koji_builds from ODCS client. +{%- if compose["builds"] %} +pkgset_koji_builds = [ +{%- for build in compose["builds"].split(" ") %} + '{{ build }}', +{%- endfor %} +] +{%- endif %} + +# Allow overriding sigkeys from ODCS client. +{%- if compose["sigkeys"] %} +sigkeys = [ +{%- for sigkey in compose["sigkeys"].split(" ") %} + '{{ sigkey }}', +{%- endfor%} +] +{%- endif %} diff --git a/roles/odcs/base/tasks/main.yml b/roles/odcs/base/tasks/main.yml index 4b661ea152..5a57074fab 100644 --- a/roles/odcs/base/tasks/main.yml +++ b/roles/odcs/base/tasks/main.yml @@ -358,3 +358,16 @@ - odcs/backend - odcs/frontend +- name: copy the custom_compose_raw_config_wrapper.conf file. + copy: + src: "{{ roles_path }}/odcs/base/files/odcs/custom_compose_raw_config_wrapper.conf" + dest: /etc/odcs/custom_compose_raw_config_wrapper.conf + owner: odcs-server + group: odcs-server + mode: 0640 + notify: + - restart odcs-celery-backend + when: inventory_hostname.startswith('odcs-backend') + tags: + - odcs + - odcs/backend