Expose limit_tenants_to_placement_aggregate parameter
Add support for configuring scheduler parameter option 'limit_tenants_to_placement_aggregate' to enable tenant isolation with placement. Change-Id: I37ce0633b3b56563f373fadfb74820b2896d6734
This commit is contained in:
parent
bb4afe7d3d
commit
09b5d82294
@ -35,6 +35,12 @@
|
|||||||
# request.
|
# request.
|
||||||
# Defaults to $::os_service_default
|
# Defaults to $::os_service_default
|
||||||
#
|
#
|
||||||
|
# [*limit_tenants_to_placement_aggregate*]
|
||||||
|
# (optional) This setting allows to have tenant isolation with placement.
|
||||||
|
# It ensures hosts in tenant-isolated host aggregate and availability
|
||||||
|
# zones will only be available to specific set of tenants.
|
||||||
|
# Defaults to $::os_service_default
|
||||||
|
#
|
||||||
class nova::scheduler(
|
class nova::scheduler(
|
||||||
$enabled = true,
|
$enabled = true,
|
||||||
$manage_service = true,
|
$manage_service = true,
|
||||||
@ -43,6 +49,7 @@ class nova::scheduler(
|
|||||||
$scheduler_driver = 'filter_scheduler',
|
$scheduler_driver = 'filter_scheduler',
|
||||||
$discover_hosts_in_cells_interval = $::os_service_default,
|
$discover_hosts_in_cells_interval = $::os_service_default,
|
||||||
$query_placement_for_image_type_support = $::os_service_default,
|
$query_placement_for_image_type_support = $::os_service_default,
|
||||||
|
$limit_tenants_to_placement_aggregate = $::os_service_default,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
include ::nova::deps
|
include ::nova::deps
|
||||||
@ -63,6 +70,7 @@ class nova::scheduler(
|
|||||||
'scheduler/driver': value => $scheduler_driver;
|
'scheduler/driver': value => $scheduler_driver;
|
||||||
'scheduler/discover_hosts_in_cells_interval': value => $discover_hosts_in_cells_interval;
|
'scheduler/discover_hosts_in_cells_interval': value => $discover_hosts_in_cells_interval;
|
||||||
'scheduler/query_placement_for_image_type_support': value => $query_placement_for_image_type_support;
|
'scheduler/query_placement_for_image_type_support': value => $query_placement_for_image_type_support;
|
||||||
|
'scheduler/limit_tenants_to_placement_aggregate': value => $limit_tenants_to_placement_aggregate;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
features:
|
||||||
|
- |
|
||||||
|
Add parameter `limit_tenants_to_placement_aggregate` which allows
|
||||||
|
to have tenant isolation with placement. It ensures hosts are in
|
||||||
|
tenant-isolated host aggregate and availability zones will only be
|
||||||
|
available to specific set of tenants.
|
@ -23,6 +23,7 @@ describe 'nova::scheduler' do
|
|||||||
it { is_expected.to contain_nova_config('scheduler/driver').with_value('filter_scheduler') }
|
it { is_expected.to contain_nova_config('scheduler/driver').with_value('filter_scheduler') }
|
||||||
it { is_expected.to contain_nova_config('scheduler/discover_hosts_in_cells_interval').with_value('<SERVICE DEFAULT>') }
|
it { is_expected.to contain_nova_config('scheduler/discover_hosts_in_cells_interval').with_value('<SERVICE DEFAULT>') }
|
||||||
it { is_expected.to contain_nova_config('scheduler/query_placement_for_image_type_support').with_value('<SERVICE DEFAULT>') }
|
it { is_expected.to contain_nova_config('scheduler/query_placement_for_image_type_support').with_value('<SERVICE DEFAULT>') }
|
||||||
|
it { is_expected.to contain_nova_config('scheduler/limit_tenants_to_placement_aggregate').with_value('<SERVICE DEFAULT>')}
|
||||||
|
|
||||||
context 'with manage_service as false' do
|
context 'with manage_service as false' do
|
||||||
let :params do
|
let :params do
|
||||||
@ -75,6 +76,14 @@ describe 'nova::scheduler' do
|
|||||||
it { is_expected.to contain_nova_config('scheduler/query_placement_for_image_type_support').with_value(true) }
|
it { is_expected.to contain_nova_config('scheduler/query_placement_for_image_type_support').with_value(true) }
|
||||||
end
|
end
|
||||||
|
|
||||||
|
context 'with limit_tenants_to_placement_aggregate' do
|
||||||
|
let :params do
|
||||||
|
{ :limit_tenants_to_placement_aggregate => true }
|
||||||
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_nova_config('scheduler/limit_tenants_to_placement_aggregate').with_value(true) }
|
||||||
|
end
|
||||||
|
|
||||||
context 'with default database parameters' do
|
context 'with default database parameters' do
|
||||||
let :pre_condition do
|
let :pre_condition do
|
||||||
"include nova"
|
"include nova"
|
||||||
|
Loading…
Reference in New Issue
Block a user