Train deprecations and removals
Change-Id: I43941b598c05c3f6529ede274d526e3a6c8910d5
This commit is contained in:
parent
e9220c8ee3
commit
fb8e19deb8
@ -183,13 +183,6 @@
|
||||
# (optional) Glance UUID or URL of a rescue ramdisk to use by default.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*enabled_drivers*]
|
||||
# (optional) Array of drivers to load during service initialization.
|
||||
# Deprecated and does nothing since the classic drivers have been removed.
|
||||
# Defaults to undef
|
||||
#
|
||||
class ironic::conductor (
|
||||
$package_ensure = 'present',
|
||||
$enabled = true,
|
||||
@ -224,7 +217,6 @@ class ironic::conductor (
|
||||
$deploy_ramdisk = $::os_service_default,
|
||||
$rescue_kernel = $::os_service_default,
|
||||
$rescue_ramdisk = $::os_service_default,
|
||||
$enabled_drivers = undef,
|
||||
) {
|
||||
|
||||
include ::ironic::deps
|
||||
@ -288,8 +280,6 @@ class ironic::conductor (
|
||||
|
||||
# Configure ironic.conf
|
||||
ironic_config {
|
||||
# Force removal of the deprecated options to avoid failures. Remove in Stein.
|
||||
'DEFAULT/enabled_drivers': ensure => absent;
|
||||
'DEFAULT/enabled_hardware_types': value => join($enabled_hardware_types, ',');
|
||||
'conductor/max_time_interval': value => $max_time_interval;
|
||||
'conductor/force_power_state_during_sync': value => $force_power_state_during_sync;
|
||||
|
@ -14,11 +14,6 @@
|
||||
#
|
||||
# Configure how Ironic talks to Ironic Inspector.
|
||||
#
|
||||
# [*service_url*]
|
||||
# Ironic Inspector API endpoint. If not provided, the service catalog
|
||||
# is used instead.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*auth_type*]
|
||||
# The authentication plugin to use when connecting to ironic-inspector.
|
||||
# Defaults to 'password'
|
||||
@ -53,13 +48,11 @@
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*enabled*]
|
||||
# Whether or not to enable ironic-inspector support for inspection.
|
||||
# This option does not affect new-style dynamic drivers and fake_inspector.
|
||||
# Defaults to $::os_service_default
|
||||
# [*service_url*]
|
||||
# Has no effect, use endpoint_override.
|
||||
# Defaults to undef
|
||||
#
|
||||
class ironic::drivers::inspector (
|
||||
$service_url = $::os_service_default,
|
||||
$auth_type = 'password',
|
||||
$auth_url = $::os_service_default,
|
||||
$project_name = 'services',
|
||||
@ -69,18 +62,17 @@ class ironic::drivers::inspector (
|
||||
$project_domain_name = 'Default',
|
||||
$endpoint_override = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$enabled = undef,
|
||||
$service_url = undef,
|
||||
) {
|
||||
|
||||
include ::ironic::deps
|
||||
|
||||
if $enabled {
|
||||
warning("The ironic::drivers::inspector::enabled parameter is deprecated. \
|
||||
Please use ironic::drivers::hardware_interfaces::enabled_inspect_interfaces instead.")
|
||||
if $service_url {
|
||||
warning("The ironic::drivers::inspector::service_url parameter is deprecated and \
|
||||
has no effect. Please use ironic::drivers::inspector::endpoint_override instead.")
|
||||
}
|
||||
|
||||
ironic_config {
|
||||
'inspector/service_url': value => $service_url;
|
||||
'inspector/auth_type': value => $auth_type;
|
||||
'inspector/username': value => $username;
|
||||
'inspector/password': value => $password, secret => true;
|
||||
|
@ -40,11 +40,6 @@
|
||||
# The name of project's domain (required for Identity V3).
|
||||
# Defaults to 'Default'
|
||||
#
|
||||
# [*api_servers*]
|
||||
# (optional) A list of the glance api servers available to ironic.
|
||||
# Should be an array with [hostname|ip]:port
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*num_retries*]
|
||||
# (optional) Number retries when downloading an image from glance.
|
||||
# Defaults to $::os_service_default
|
||||
@ -89,6 +84,12 @@
|
||||
# The endpoint URL for requests for this client
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*api_servers*]
|
||||
# Has no effect, use endpoint_override.
|
||||
# Defaults to undef
|
||||
#
|
||||
class ironic::glance (
|
||||
$auth_type = 'password',
|
||||
$auth_url = $::os_service_default,
|
||||
@ -97,7 +98,6 @@ class ironic::glance (
|
||||
$password = $::os_service_default,
|
||||
$user_domain_name = 'Default',
|
||||
$project_domain_name = 'Default',
|
||||
$api_servers = $::os_service_default,
|
||||
$num_retries = $::os_service_default,
|
||||
$api_insecure = $::os_service_default,
|
||||
$swift_account = $::os_service_default,
|
||||
@ -107,12 +107,13 @@ class ironic::glance (
|
||||
$swift_temp_url_duration = $::os_service_default,
|
||||
$swift_account_project_name = undef,
|
||||
$endpoint_override = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$api_servers = undef,
|
||||
) {
|
||||
|
||||
if is_array($api_servers) {
|
||||
$api_servers_converted = join($api_servers, ',')
|
||||
} else {
|
||||
$api_servers_converted = $api_servers
|
||||
if $api_servers {
|
||||
warning("The ironic::glance::api_servers parameter is deprecated and \
|
||||
has no effect. Please use ironic::glance::endpoint_override instead.")
|
||||
}
|
||||
|
||||
if ($swift_account_project_name and !is_service_default($swift_account)) {
|
||||
@ -127,9 +128,8 @@ class ironic::glance (
|
||||
'glance/project_name': value => $project_name;
|
||||
'glance/user_domain_name': value => $user_domain_name;
|
||||
'glance/project_domain_name': value => $project_domain_name;
|
||||
'glance/glance_api_servers': value => $api_servers_converted;
|
||||
'glance/glance_num_retries': value => $num_retries;
|
||||
'glance/glance_api_insecure': value => $api_insecure;
|
||||
'glance/num_retries': value => $num_retries;
|
||||
'glance/insecure': value => $api_insecure;
|
||||
'glance/swift_container': value => $swift_container;
|
||||
'glance/swift_endpoint_url': value => $swift_endpoint_url;
|
||||
'glance/swift_temp_url_key': value => $swift_temp_url_key, secret => true;
|
||||
|
@ -12,10 +12,6 @@
|
||||
#
|
||||
# == Class: ironic::neutron
|
||||
#
|
||||
# [*api_endpoint*]
|
||||
# (optional) The Neutron URL to be used for requests from ironic
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*auth_type*]
|
||||
# The authentication plugin to use when connecting to neutron.
|
||||
# Defaults to 'password'
|
||||
@ -48,8 +44,13 @@
|
||||
# The endpoint URL for requests for this client
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*api_endpoint*]
|
||||
# Has no effect, use endpoint_override.
|
||||
# Defaults to undef
|
||||
#
|
||||
class ironic::neutron (
|
||||
$api_endpoint = $::os_service_default,
|
||||
$auth_type = 'password',
|
||||
$auth_url = $::os_service_default,
|
||||
$project_name = 'services',
|
||||
@ -58,10 +59,16 @@ class ironic::neutron (
|
||||
$user_domain_name = 'Default',
|
||||
$project_domain_name = 'Default',
|
||||
$endpoint_override = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$api_endpoint = undef,
|
||||
) {
|
||||
|
||||
if $api_endpoint {
|
||||
warning("The ironic::neutron::api_endpoint parameter is deprecated and \
|
||||
has no effect. Please use ironic::neutron::endpoint_override instead.")
|
||||
}
|
||||
|
||||
ironic_config {
|
||||
'neutron/url': value => $api_endpoint;
|
||||
'neutron/auth_type': value => $auth_type;
|
||||
'neutron/username': value => $username;
|
||||
'neutron/password': value => $password, secret => true;
|
||||
|
21
releasenotes/notes/train-deprecations-06c3472b1703a4c7.yaml
Normal file
21
releasenotes/notes/train-deprecations-06c3472b1703a4c7.yaml
Normal file
@ -0,0 +1,21 @@
|
||||
---
|
||||
upgrade:
|
||||
- |
|
||||
The deprecated parameter ``ironic::conductor::enabled_drivers`` has been
|
||||
removed. Use new-style hardware types and the
|
||||
``ironic::conductor::enabled_hardware_types`` parameter instead.
|
||||
- |
|
||||
The deprecated parameter ``ironic::drivers::inspector::enabled`` has been
|
||||
removed. Use
|
||||
``ironic::drivers::hardware_interfaces::enabled_inspect_interfaces`` to
|
||||
enable ironic-inspector support.
|
||||
deprecations:
|
||||
- |
|
||||
The parameter ``ironic::drivers::inspector::service_url`` is deprecated and
|
||||
has no effect. Use ``ironic::drivers::inspector::endpoint_override``.
|
||||
- |
|
||||
The parameter ``ironic::glance::api_servers`` is deprecated and
|
||||
has no effect. Use ``ironic::glance::endpoint_override``.
|
||||
- |
|
||||
The parameter ``ironic::neutron::api_endpoint`` is deprecated and
|
||||
has no effect. Use ``ironic::neutron::endpoint_override``.
|
@ -62,7 +62,6 @@ describe 'ironic::conductor' do
|
||||
end
|
||||
|
||||
it 'configures ironic.conf' do
|
||||
is_expected.to contain_ironic_config('DEFAULT/enabled_drivers').with_ensure('absent')
|
||||
is_expected.to contain_ironic_config('DEFAULT/enabled_hardware_types').with_value('ipmi')
|
||||
is_expected.to contain_ironic_config('conductor/max_time_interval').with_value(p[:max_time_interval])
|
||||
is_expected.to contain_ironic_config('conductor/force_power_state_during_sync').with_value(p[:force_power_state_during_sync])
|
||||
|
@ -34,7 +34,6 @@ describe 'ironic::drivers::inspector' do
|
||||
end
|
||||
|
||||
it 'configures ironic.conf' do
|
||||
is_expected.to contain_ironic_config('inspector/service_url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('inspector/auth_type').with_value(p[:auth_type])
|
||||
is_expected.to contain_ironic_config('inspector/auth_url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('inspector/project_name').with_value(p[:project_name])
|
||||
@ -48,7 +47,6 @@ describe 'ironic::drivers::inspector' do
|
||||
context 'when overriding parameters' do
|
||||
before :each do
|
||||
params.merge!(
|
||||
:service_url => 'http://example.com/inspector',
|
||||
:auth_type => 'noauth',
|
||||
:auth_url => 'http://example.com',
|
||||
:project_name => 'project1',
|
||||
@ -61,7 +59,6 @@ describe 'ironic::drivers::inspector' do
|
||||
end
|
||||
|
||||
it 'should replace default parameter with new value' do
|
||||
is_expected.to contain_ironic_config('inspector/service_url').with_value(p[:service_url])
|
||||
is_expected.to contain_ironic_config('inspector/auth_type').with_value(p[:auth_type])
|
||||
is_expected.to contain_ironic_config('inspector/auth_url').with_value(p[:auth_url])
|
||||
is_expected.to contain_ironic_config('inspector/project_name').with_value(p[:project_name])
|
||||
|
@ -41,9 +41,8 @@ describe 'ironic::glance' do
|
||||
is_expected.to contain_ironic_config('glance/password').with_value('<SERVICE DEFAULT>').with_secret(true)
|
||||
is_expected.to contain_ironic_config('glance/user_domain_name').with_value('Default')
|
||||
is_expected.to contain_ironic_config('glance/project_domain_name').with_value('Default')
|
||||
is_expected.to contain_ironic_config('glance/glance_api_servers').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/glance_api_insecure').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/glance_num_retries').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/insecure').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/num_retries').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/swift_account').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/swift_container').with(:value => '<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('glance/swift_endpoint_url').with(:value => '<SERVICE DEFAULT>')
|
||||
@ -82,9 +81,8 @@ describe 'ironic::glance' do
|
||||
is_expected.to contain_ironic_config('glance/password').with_value(p[:password]).with_secret(true)
|
||||
is_expected.to contain_ironic_config('glance/user_domain_name').with_value(p[:user_domain_name])
|
||||
is_expected.to contain_ironic_config('glance/project_domain_name').with_value(p[:project_domain_name])
|
||||
is_expected.to contain_ironic_config('glance/glance_api_servers').with_value(p[:api_servers])
|
||||
is_expected.to contain_ironic_config('glance/glance_api_insecure').with_value(p[:api_insecure])
|
||||
is_expected.to contain_ironic_config('glance/glance_num_retries').with_value(p[:num_retries])
|
||||
is_expected.to contain_ironic_config('glance/insecure').with_value(p[:api_insecure])
|
||||
is_expected.to contain_ironic_config('glance/num_retries').with_value(p[:num_retries])
|
||||
is_expected.to contain_ironic_config('glance/swift_account').with_value(p[:swift_account])
|
||||
is_expected.to contain_ironic_config('glance/swift_container').with_value(p[:swift_container])
|
||||
is_expected.to contain_ironic_config('glance/swift_endpoint_url').with_value(p[:swift_endpoint_url])
|
||||
@ -94,38 +92,6 @@ describe 'ironic::glance' do
|
||||
end
|
||||
end
|
||||
|
||||
context 'when overriding parameters with 2 glance servers' do
|
||||
before :each do
|
||||
params.merge!(
|
||||
:auth_type => 'noauth',
|
||||
:auth_url => 'http://example.com',
|
||||
:project_name => 'project1',
|
||||
:username => 'admin',
|
||||
:password => 'pa$$w0rd',
|
||||
:user_domain_name => 'NonDefault',
|
||||
:project_domain_name => 'NonDefault',
|
||||
:api_servers => ['10.0.0.1:9292','10.0.0.2:9292'],
|
||||
:api_insecure => true,
|
||||
:num_retries => 42,
|
||||
:endpoint_override => 'http://example2.com',
|
||||
)
|
||||
end
|
||||
|
||||
it 'should replace default parameter with new value' do
|
||||
is_expected.to contain_ironic_config('glance/auth_type').with_value(p[:auth_type])
|
||||
is_expected.to contain_ironic_config('glance/auth_url').with_value(p[:auth_url])
|
||||
is_expected.to contain_ironic_config('glance/project_name').with_value(p[:project_name])
|
||||
is_expected.to contain_ironic_config('glance/username').with_value(p[:username])
|
||||
is_expected.to contain_ironic_config('glance/password').with_value(p[:password]).with_secret(true)
|
||||
is_expected.to contain_ironic_config('glance/user_domain_name').with_value(p[:user_domain_name])
|
||||
is_expected.to contain_ironic_config('glance/project_domain_name').with_value(p[:project_domain_name])
|
||||
is_expected.to contain_ironic_config('glance/glance_api_servers').with_value(p[:api_servers].join(','))
|
||||
is_expected.to contain_ironic_config('glance/glance_api_insecure').with_value(p[:api_insecure])
|
||||
is_expected.to contain_ironic_config('glance/glance_num_retries').with_value(p[:num_retries])
|
||||
is_expected.to contain_ironic_config('glance/endpoint_override').with_value(p[:endpoint_override])
|
||||
end
|
||||
end
|
||||
|
||||
context 'when overriding parameters swift_account_project_name' do
|
||||
before :each do
|
||||
params.merge!(
|
||||
|
@ -34,7 +34,6 @@ describe 'ironic::neutron' do
|
||||
end
|
||||
|
||||
it 'configures ironic.conf' do
|
||||
is_expected.to contain_ironic_config('neutron/url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('neutron/auth_type').with_value(p[:auth_type])
|
||||
is_expected.to contain_ironic_config('neutron/auth_url').with_value('<SERVICE DEFAULT>')
|
||||
is_expected.to contain_ironic_config('neutron/project_name').with_value(p[:project_name])
|
||||
@ -48,7 +47,6 @@ describe 'ironic::neutron' do
|
||||
context 'when overriding parameters' do
|
||||
before :each do
|
||||
params.merge!(
|
||||
:api_endpoint => 'http://neutron.example.com',
|
||||
:auth_type => 'noauth',
|
||||
:auth_url => 'http://example.com',
|
||||
:project_name => 'project1',
|
||||
@ -61,7 +59,6 @@ describe 'ironic::neutron' do
|
||||
end
|
||||
|
||||
it 'should replace default parameter with new value' do
|
||||
is_expected.to contain_ironic_config('neutron/url').with_value(p[:api_endpoint])
|
||||
is_expected.to contain_ironic_config('neutron/auth_type').with_value(p[:auth_type])
|
||||
is_expected.to contain_ironic_config('neutron/auth_url').with_value(p[:auth_url])
|
||||
is_expected.to contain_ironic_config('neutron/project_name').with_value(p[:project_name])
|
||||
|
Loading…
x
Reference in New Issue
Block a user