Skip to content

Commit

Permalink
Use if instead of elif to set container overrides
Browse files Browse the repository at this point in the history
Currently set_openstack_containers either updates the operator
environment variables or apply the overrides. It does not perform
both the things together.

In downstream for post-adoption job, we want to update the environment
variable as well as overrides. By changing the condition to if, we can
achieve the same.

Signed-off-by: Chandan Kumar (raukadah) <[email protected]>
  • Loading branch information
raukadah authored and openshift-merge-bot[bot] committed Sep 11, 2024
1 parent 002b302 commit e581562
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@ export PATH="{{ cifmw_path }}"
{% endif -%}
{% set _container_address = _container_registry + '/' + _container_prefix + _container_name + ':' + cifmw_set_openstack_containers_tag -%}
{% set _ = containers_dict.update({_container_env: _container_address}) -%}
{% endif -%}
{# This section overrides the non openstack services containers #}
{% elif cifmw_set_openstack_containers_overrides.keys() | length > 0 -%}
{% if cifmw_set_openstack_containers_overrides.keys() | length > 0 -%}
{% if _container_env in cifmw_set_openstack_containers_overrides.keys() -%}
{% set _ = containers_dict.update({_container_env: cifmw_set_openstack_containers_overrides[_container_env]}) -%}
{% endif -%}
Expand Down

0 comments on commit e581562

Please sign in to comment.