Drop redundant installation of xorriso/genisoimage

The xorriso package (in Red Hat) or the genisoimage package (in Debian
or Ubuntu) is installed automatically as part of dependencies.

Red Hat:
 openstack-nova-compute depends on xorriso

Debian/Ubuntu:
 nova-compute-kvm/qemu depends on nova-compute-libvirt
 nova-compute-libvirt depends on genisoimage

Change-Id: Id51ff306b94d8304dfbb0ca198c15de7132f7d1d
This commit is contained in:
Takashi Kajinami
2023-11-03 16:08:36 +09:00
parent 1c2f147c2a
commit e0b5069677
3 changed files with 4 additions and 28 deletions

View File

@@ -462,14 +462,8 @@ class nova::compute (
}
}
$config_drive_format_real = pick($config_drive_format, $facts['os_service_default'])
if is_service_default($config_drive_format_real) or $config_drive_format_real == 'iso9660' {
ensure_packages($::nova::params::mkisofs_package_name, {
tag => ['openstack', 'nova-support-package'],
})
}
nova_config {
'DEFAULT/config_drive_format': value => $config_drive_format_real;
'DEFAULT/config_drive_format': value => pick($config_drive_format, $facts['os_service_default']);
}
}

View File

@@ -33,7 +33,6 @@ class nova::params {
$serialproxy_package_name = 'openstack-nova-serialproxy'
$spicehtml5proxy_package_name = 'openstack-nova-console'
$ceph_client_package_name = 'ceph-common'
$mkisofs_package_name = 'xorriso'
$mkisofs_cmd = 'mkisofs'
$ovmf_package_name = 'edk2-ovmf'
$swtpm_package_name = 'swtpm'
@@ -83,8 +82,7 @@ class nova::params {
$scheduler_package_name = 'nova-scheduler'
$tgt_package_name = 'tgt'
$ceph_client_package_name = 'ceph-common'
$mkisofs_package_name = 'genisoimage'
$mkisofs_cmd = false
$mkisofs_cmd = undef
$ovmf_package_name = 'ovmf'
$swtpm_package_name = 'swtpm'
# service names

View File

@@ -66,6 +66,7 @@ describe 'nova::compute' do
it { is_expected.to contain_nova_config('compute/image_type_exclude_list').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('DEFAULT/block_device_allocate_retries').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('DEFAULT/block_device_allocate_retries_interval').with_value('<SERVICE DEFAULT>') }
it { is_expected.to contain_nova_config('DEFAULT/config_drive_format').with_value('<SERVICE DEFAULT>') }
it { is_expected.to_not contain_package('bridge-utils').with(
:ensure => 'present',
@@ -73,15 +74,6 @@ describe 'nova::compute' do
it { is_expected.to contain_class('nova::policy') }
it { is_expected.to contain_class('nova::availability_zone') }
it 'installs mkisofs package and sets config_drive_format' do
is_expected.to contain_nova_config('DEFAULT/config_drive_format').with_value('<SERVICE DEFAULT>')
is_expected.to contain_package(platform_params[:mkisofs_package]).with(
:ensure => 'installed',
)
is_expected.to contain_package(platform_params[:mkisofs_package]).that_requires('Anchor[nova::install::begin]')
is_expected.to contain_package(platform_params[:mkisofs_package]).that_comes_before('Anchor[nova::install::end]')
end
end
context 'with overridden parameters' do
@@ -182,13 +174,7 @@ describe 'nova::compute' do
it { is_expected.to contain_nova_config('compute/image_type_exclude_list').with_value('raw,ami') }
it { is_expected.to contain_nova_config('DEFAULT/block_device_allocate_retries').with_value(60) }
it { is_expected.to contain_nova_config('DEFAULT/block_device_allocate_retries_interval').with_value(3) }
it 'configures nova config_drive_format to vfat' do
is_expected.to contain_nova_config('DEFAULT/config_drive_format').with_value('vfat')
is_expected.to_not contain_package(platform_params[:mkisofs_package]).with(
:ensure => 'present',
)
end
it { is_expected.to contain_nova_config('DEFAULT/config_drive_format').with_value('vfat') }
end
context 'with image_type_exclude_list set to empty list' do
@@ -354,7 +340,6 @@ describe 'nova::compute' do
{
:nova_compute_package => 'nova-compute',
:nova_compute_service => 'nova-compute',
:mkisofs_package => 'genisoimage',
:mkisofs_cmd => '<SERVICE DEFAULT>'
}
end
@@ -363,7 +348,6 @@ describe 'nova::compute' do
{
:nova_compute_package => 'openstack-nova-compute',
:nova_compute_service => 'openstack-nova-compute',
:mkisofs_package => 'xorriso',
:mkisofs_cmd => 'mkisofs'
}
end