Support setting the default_resource_class option

Change-Id: I4f27bc75e04229fa836c386c4800979074e2827e
Depends-On: I58232d9c92d6ffca49d334e5fb7078bce19f1cb4
Closes-Bug: #1732190
This commit is contained in:
Dmitry Tantsur 2017-11-27 12:11:32 +01:00
parent b6ecd21a67
commit 907e5b9613
3 changed files with 12 additions and 0 deletions

View File

@ -43,6 +43,11 @@
# (optional) Default protocol to use when connecting to glance
# Defaults to 'keystone'. 'https' is the only other valid option for SSL
#
# [*default_resource_class*]
# (optional) Default resource class to use for new nodes when no resource
# class is explicitly requested.
# Defaults to $::os_service_default
#
# [*rpc_response_timeout*]
# (optional) Seconds to wait for a response from a call. (integer value)
# Defaults to $::os_service_default.
@ -293,6 +298,7 @@ class ironic (
$log_facility = undef,
$log_dir = undef,
$auth_strategy = 'keystone',
$default_resource_class = $::os_service_default,
$control_exchange = $::os_service_default,
$rpc_response_timeout = $::os_service_default,
$default_transport_url = $::os_service_default,
@ -392,6 +398,7 @@ ironic::glance::api_insecure and ironic::glance::num_retries accordingly")
ironic_config {
'DEFAULT/auth_strategy': value => $auth_strategy;
'DEFAULT/my_ip': value => $my_ip;
'DEFAULT/default_resource_class': value => $default_resource_class;
}
if $sync_db {

View File

@ -0,0 +1,4 @@
---
features:
- |
Adds support for setting the ``default_resource_class`` option.

View File

@ -116,6 +116,7 @@ describe 'ironic' do
is_expected.to contain_ironic_config('DEFAULT/rpc_response_timeout').with_value('<SERVICE DEFAULT>')
is_expected.to contain_ironic_config('DEFAULT/control_exchange').with_value('<SERVICE DEFAULT>')
is_expected.to contain_ironic_config('DEFAULT/transport_url').with_value('<SERVICE DEFAULT>').with_secret(true)
is_expected.to contain_ironic_config('DEFAULT/default_resource_class').with_value('<SERVICE DEFAULT>')
end
end