Skip to content

Commit

Permalink
kuttl: fetch the locally built operators
Browse files Browse the repository at this point in the history
Make sure that locally built operator (for example, thanks to the
openstack-k8s-operators-content-provider job, or anything else
which populates cifmw_operator_build_output) are used.
This is a bit more complex than what EDPM jobs do (see the edpm_prepare
role), where only the openstack-operator-index is overridden,
likely because here there may be more operators being built.
  • Loading branch information
tosky authored and openshift-merge-bot[bot] committed Nov 26, 2024
1 parent 587205f commit 794cc44
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion ci/playbooks/kuttl/run-kuttl-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,23 @@
ansible.builtin.include_vars:
dir: "{{ cifmw_basedir }}/artifacts/parameters"

- name: Use the locally built operators if any
ansible.builtin.set_fact:
_local_operators_indexes:
"{{ _local_operators_indexes|default({}) |
combine({ item.key.split('-')[0]|upper+'_IMG':
cifmw_operator_build_output['operators'][item.key].image_catalog}) }}"
loop: "{{ cifmw_operator_build_output['operators'] | dict2items }}"
when:
- cifmw_operator_build_output is defined
- "'operators' in cifmw_operator_build_output"

- name: Set environment vars for kuttl test
ansible.builtin.set_fact:
cifmw_kuttl_tests_env: >-
{{
cifmw_install_yamls_environment |
_local_operators_indexes | default({}) |
combine(cifmw_install_yamls_environment) |
combine(cifmw_kuttl_tests_env_vars | default({})) |
combine(cifmw_kuttl_openstack_prep_vars | default({})) |
combine({'PATH': cifmw_path})
Expand Down

0 comments on commit 794cc44

Please sign in to comment.