Improve Blazar integration with Nova

As of today we do not have any means of Blazar integration with Nova,
while we do provide roles for Blazar installation for a while now. This
patch aims to bring in more native integration and remove necessity
of overrides for such deployment.

Related-Bug: #2048048
Co-Authored-By: Alexey Rusetsky <fenuks@fenuks.ru>
Change-Id: Ica50a5504de1b1604f72123751cbb3f45c85ab46
This commit is contained in:
Dmitriy Rabotyagov 2024-01-04 18:13:31 +01:00 committed by Fenuks
parent 20e83153bb
commit 5a533aae23
4 changed files with 31 additions and 0 deletions

View File

@ -16,6 +16,8 @@
# Enable/Disable barbican configurations
nova_barbican_enabled: "{{ (groups['barbican_all'] is defined) and (groups['barbican_all'] | length > 0) }}"
# Enable/Disable blazar configurations
nova_blazar_enabled: "{{ (groups['blazar_all'] is defined) and (groups['blazar_all'] | length > 0) }}"
# Enable/Disable designate configurations
nova_designate_enabled: "{{ (groups['designate_all'] is defined) and (groups['designate_all'] | length > 0) }}"
# Notification topics for designate.
@ -358,6 +360,9 @@ nova_scheduler_default_filters:
- ServerGroupAffinityFilter
- NUMATopologyFilter
nova_blazar_scheduler_filters:
- BlazarFilter
nova_scheduler_extra_filters: []
# This should be tuned depending on the number of compute hosts present in the
@ -538,6 +543,9 @@ nova_services:
start_order: 5
execstarts: "{{ nova_bin }}/nova-serialproxy {{ nova_backend_ssl | ternary('--ssl_only --cert ' ~ nova_ssl_cert ~ ' --key ' ~ nova_ssl_key, '') }}"
nova_blazar_pip_packages:
- blazar-nova
nova_novnc_pip_packages:
- websockify

View File

@ -0,0 +1,11 @@
---
features:
- |
Added extra variables to allow control Blazar integration with Nova:
* ``nova_blazar_enabled`` (bool) - Control if Blazar integration should
be configured
* ``nova_blazar_scheduler_filters`` (list) - Extra filters that will be
enabled in Nova scheduler
* ``nova_blazar_pip_packages`` (list) - Extra Python packages that will
be installed on Nova scheduler hosts

View File

@ -317,6 +317,10 @@ discover_hosts_in_cells_interval = {{ nova_discover_hosts_in_cells_interval }}
[filter_scheduler]
max_io_ops_per_host = {{ nova_max_io_ops_per_host }}
{% if nova_blazar_enabled and nova_blazar_scheduler_filters %}
available_filters = nova.scheduler.filters.all_filters
available_filters = blazarnova.scheduler.filters.blazar_filter.BlazarFilter
{% endif %}
enabled_filters = {{ _nova_scheduler_filters | join(',') }}
host_subset_size = {{ nova_scheduler_host_subset_size }}
track_instance_changes = {{ nova_scheduler_tracks_instance_changes }}

View File

@ -47,6 +47,11 @@ nova_venv_packages: |-
{%- if nova_oslomsg_amqp1_enabled | bool %}
{%- set _ = pkg_list.extend(nova_optional_oslomsg_amqp1_pip_packages) %}
{%- endif %}
{%- if nova_blazar_enabled | bool %}
{%- if (nova_services['nova-scheduler']['group'] in group_names) %}
{%- set _ = pkg_list.extend(nova_blazar_pip_packages) %}
{%- endif %}
{%- endif %}
{%- if ('novnc' in nova_console_proxy_types) %}
{%- set _ = pkg_list.extend(nova_novnc_pip_packages) %}
{%- endif %}
@ -137,6 +142,9 @@ _nova_scheduler_filters: |-
{% else %}
{% set filters = default_filters %}
{% endif %}
{% if nova_blazar_enabled | bool %}
{% set _ = filters.extend(nova_blazar_scheduler_filters) %}
{% endif %}
{{ filters + nova_scheduler_extra_filters }}
_qemu_default_conf_dict: |-