Add support for [compute] reserved_host_cpus
Change-Id: I7b30d1ad19c1a950c14171bc2a150d9ab8ead248
This commit is contained in:
@@ -80,14 +80,16 @@
|
||||
# The format is <os_type>=<mkfs command>
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*reserved_host_cpus*]
|
||||
# (optional) Number of host CPUs reserved for the host.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*reserved_host_memory*]
|
||||
# Reserved host memory
|
||||
# The amount of memory in MB reserved for the host.
|
||||
# (optional) The amount of memory in MB reserved for the host.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*reserved_host_disk*]
|
||||
# Reserved host disk
|
||||
# The amount of disk in MB reserved for the host.
|
||||
# (optional) The amount of disk in MB reserved for the host.
|
||||
# Defaults to $facts['os_service_default']
|
||||
#
|
||||
# [*config_drive_format*]
|
||||
@@ -271,6 +273,7 @@ class nova::compute (
|
||||
$use_cow_images = $facts['os_service_default'],
|
||||
$force_raw_images = $facts['os_service_default'],
|
||||
$virt_mkfs = $facts['os_service_default'],
|
||||
$reserved_host_cpus = $facts['os_service_default'],
|
||||
$reserved_host_memory = $facts['os_service_default'],
|
||||
$reserved_host_disk = $facts['os_service_default'],
|
||||
$heal_instance_info_cache_interval = $facts['os_service_default'],
|
||||
@@ -376,6 +379,7 @@ class nova::compute (
|
||||
'DEFAULT/mkisofs_cmd': value => $mkisofs_cmd_real;
|
||||
'DEFAULT/force_raw_images': value => $force_raw_images;
|
||||
'DEFAULT/virt_mkfs': value => $virt_mkfs;
|
||||
'DEFAULT/reserved_host_cpus': value => $reserved_host_cpus;
|
||||
'DEFAULT/reserved_host_memory_mb': value => $reserved_host_memory;
|
||||
'DEFAULT/reserved_host_disk_mb': value => $reserved_host_disk;
|
||||
'DEFAULT/reserved_huge_pages': value => $reserved_huge_pages_real;
|
||||
|
@@ -0,0 +1,4 @@
|
||||
---
|
||||
features:
|
||||
- |
|
||||
The new ``nova::compute::reserved_host_cpus`` parameter has been added.
|
@@ -38,6 +38,7 @@ describe 'nova::compute' do
|
||||
it { is_expected.to contain_nova_config('DEFAULT/mkisofs_cmd').with_value(platform_params[:mkisofs_cmd]) }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/force_raw_images').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/virt_mkfs').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_cpus').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_memory_mb').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_disk_mb').with_value('<SERVICE DEFAULT>') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_huge_pages').with_value('<SERVICE DEFAULT>') }
|
||||
@@ -92,8 +93,9 @@ describe 'nova::compute' do
|
||||
:mkisofs_cmd => 'mkisofs',
|
||||
:force_raw_images => false,
|
||||
:virt_mkfs => 'windows=mkfs.ntfs --force --fast %(target)s',
|
||||
:reserved_host_memory => '0',
|
||||
:reserved_host_disk => '20',
|
||||
:reserved_host_cpus => 2,
|
||||
:reserved_host_memory => 0,
|
||||
:reserved_host_disk => 20,
|
||||
:heal_instance_info_cache_interval => '120',
|
||||
:config_drive_format => 'vfat',
|
||||
:update_resources_interval => '300',
|
||||
@@ -153,8 +155,9 @@ describe 'nova::compute' do
|
||||
it { is_expected.to contain_nova_config('DEFAULT/mkisofs_cmd').with_value('mkisofs') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/force_raw_images').with_value(false) }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/virt_mkfs').with_value('windows=mkfs.ntfs --force --fast %(target)s') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_memory_mb').with_value('0') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_disk_mb').with_value('20') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_cpus').with_value(2) }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_memory_mb').with_value(0) }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reserved_host_disk_mb').with_value(20) }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/heal_instance_info_cache_interval').with_value('120') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/update_resources_interval').with_value('300') }
|
||||
it { is_expected.to contain_nova_config('DEFAULT/reboot_timeout').with_value('180') }
|
||||
|
Reference in New Issue
Block a user