Fix lack of constraints for ironic-inspector

OSA playbooks only call this role once for all Ironic containers
(API and inspector). As a result, the wheel builds only happen
once. If the first host (which is responsible for wheel builds)
is an API container, these vars would prevent Ironic inspector
requirements being accounted for, and as such no matching
constraints will be generated.

When the venv is deployed to the Ironic inspector container,
the lack of constraints can cause dependencies which are too new
to be installed, causing the service to fail.

Alternatively this role could be called twice by the playbook
for differing container/host roles, but as inspector is expected
to be merged into ironic at some point this feels equally valid.

Change-Id: I3952a4e5514824381410d87ed6d535f13ec40498
(cherry picked from commit a665f45a69)
This commit is contained in:
Andrew Bonney 2023-08-02 14:38:42 +01:00 committed by Jonathan Rosser
parent e1a0f2bf96
commit d700ff19af
1 changed files with 2 additions and 4 deletions

View File

@ -328,10 +328,8 @@ ironic_venv_packages: |-
{%- if (ironic_oslomsg_amqp1_enabled | bool) %}
{%- set _ = pkg_list.extend(ironic_optional_oslomsg_amqp1_pip_packages) %}
{%- endif %}
{%- if (ironic_services['ironic-inspector']['group'] in group_names) %}
{%- set _ = pkg_list.extend(ironic_inspector_pip_packages) %}
{%- set _ = pkg_list.extend(ironic_inspector_user_pip_packages) %}
{%- endif %}
{%- set _ = pkg_list.extend(ironic_inspector_pip_packages) %}
{%- set _ = pkg_list.extend(ironic_inspector_user_pip_packages) %}
{{- pkg_list | unique }}
ironic_ipmitool_socat_distro_packages: