Fix error in configure_nova_hypervisor with hardware Ironic node

Trying to deploy OpenStack environment consisting of ironic nova
hypervisor & hardware Ironic node (not VM Ironic node) with devstack
got failed.

Devstack error says error occurred while calling configure_libvirt
in configure_nova_hypervisor. This happens because libvirt related
packages are not installed when specifying "VIRT_DRIVER=ironic"
and "IRONIC_IS_HARDWARE=True".

To fix this problem, this commit add "if" statement to check
Ironic node is hardware or not using "is_ironic_hardware" function
in "function-common" file.

Change-Id: I1113478175fadec79d0f8bf6ae842ed86e5e686b
Closes-Bug: #1834985
This commit is contained in:
Vanou Ishii 2019-07-02 00:40:24 -04:00 committed by Yushiro FURUKAWA
parent 15c64f109e
commit 705e9cb5dc

View File

@ -36,7 +36,9 @@ function cleanup_nova_hypervisor {
# configure_nova_hypervisor - Set config files, create data dirs, etc # configure_nova_hypervisor - Set config files, create data dirs, etc
function configure_nova_hypervisor { function configure_nova_hypervisor {
if ! is_ironic_hardware; then
configure_libvirt configure_libvirt
fi
LIBVIRT_FIREWALL_DRIVER=${LIBVIRT_FIREWALL_DRIVER:-"nova.virt.firewall.NoopFirewallDriver"} LIBVIRT_FIREWALL_DRIVER=${LIBVIRT_FIREWALL_DRIVER:-"nova.virt.firewall.NoopFirewallDriver"}
iniset $NOVA_CONF DEFAULT compute_driver ironic.IronicDriver iniset $NOVA_CONF DEFAULT compute_driver ironic.IronicDriver