Deprecate parameters for XenAPI support
... because it was already deprecated in neutron[1]. [1] a6dbf97242caa3be646e8eb6b1502b5e59e123fd Change-Id: I90a205df7817a28574e494ec7e1d497ee320a493
This commit is contained in:
@@ -4,33 +4,42 @@
|
|||||||
#
|
#
|
||||||
# === Parameters:
|
# === Parameters:
|
||||||
#
|
#
|
||||||
|
# DEPRECATED PARAMETERS
|
||||||
|
#
|
||||||
# [*xenapi_connection_url*]
|
# [*xenapi_connection_url*]
|
||||||
# (optional) XenAPI connection URL. Only needed when target a XenServer/XCP
|
# (optional) XenAPI connection URL. Only needed when target a XenServer/XCP
|
||||||
# compute host's dom0
|
# compute host's dom0
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to undef.
|
||||||
#
|
#
|
||||||
# [*xenapi_connection_username*]
|
# [*xenapi_connection_username*]
|
||||||
# (optional) XenAPI username. Only needed when target a XenServer/XCP
|
# (optional) XenAPI username. Only needed when target a XenServer/XCP
|
||||||
# compute host's dom0
|
# compute host's dom0
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to undef.
|
||||||
#
|
#
|
||||||
# [*xenapi_connection_password*]
|
# [*xenapi_connection_password*]
|
||||||
# (optional) XenAPI connection password. Only needed when target a XenServer/XCP
|
# (optional) XenAPI connection password. Only needed when target a XenServer/XCP
|
||||||
# compute host's dom0
|
# compute host's dom0
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to undef.
|
||||||
#
|
#
|
||||||
class neutron::rootwrap (
|
class neutron::rootwrap (
|
||||||
$xenapi_connection_url = $::os_service_default,
|
# DEPRECATED PARAMETERS
|
||||||
$xenapi_connection_username = $::os_service_default,
|
$xenapi_connection_url = undef,
|
||||||
$xenapi_connection_password = $::os_service_default,
|
$xenapi_connection_username = undef,
|
||||||
|
$xenapi_connection_password = undef,
|
||||||
) {
|
) {
|
||||||
|
|
||||||
include neutron::deps
|
include neutron::deps
|
||||||
|
|
||||||
neutron_rootwrap_config {
|
$deprecated_xenapi_param_names = [
|
||||||
'xenapi/xenapi_connection_url': value => $xenapi_connection_url;
|
'xenapi_connection_url',
|
||||||
'xenapi/xenapi_connection_username': value => $xenapi_connection_username;
|
'xenapi_connection_username',
|
||||||
'xenapi/xenapi_connection_password': value => $xenapi_connection_password;
|
'xenapi_connection_password',
|
||||||
|
]
|
||||||
|
$deprecated_xenapi_param_names.each |$param_name| {
|
||||||
|
$param = getvar($param_name)
|
||||||
|
if $param != undef {
|
||||||
|
warning("The ${param_name} parameter is deprecated and has no effect.")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@@ -0,0 +1,9 @@
|
|||||||
|
---
|
||||||
|
deprecations:
|
||||||
|
- |
|
||||||
|
The following parameters of the ``neutron::rootwrap`` class have been
|
||||||
|
deprecated and have no effect.
|
||||||
|
|
||||||
|
- ``xenapi_connection_url``
|
||||||
|
- ``xenapi_connection_username``
|
||||||
|
- ``xenapi_connection_password``
|
@@ -1,25 +1,14 @@
|
|||||||
require 'spec_helper'
|
require 'spec_helper'
|
||||||
|
|
||||||
describe 'neutron::rootwrap' do
|
describe 'neutron::rootwrap' do
|
||||||
let :pre_condition do
|
|
||||||
"class { 'neutron::agents::ml2::ovs': }"
|
|
||||||
end
|
|
||||||
|
|
||||||
let :params do
|
let :params do
|
||||||
{ :xenapi_connection_url => 'http://127.0.0.1',
|
{}
|
||||||
:xenapi_connection_username => 'user',
|
|
||||||
:xenapi_connection_password => 'passw0rd',
|
|
||||||
}
|
|
||||||
end
|
end
|
||||||
|
|
||||||
shared_examples 'neutron rootwrap' do
|
shared_examples 'neutron rootwrap' do
|
||||||
|
|
||||||
it 'configures rootwrap.conf' do
|
it 'configures rootwrap.conf' do
|
||||||
should contain_neutron_rootwrap_config('xenapi/xenapi_connection_url').with_value(params[:xenapi_connection_url]);
|
# Now this class doesn't have any effective parameters
|
||||||
should contain_neutron_rootwrap_config('xenapi/xenapi_connection_username').with_value(params[:xenapi_connection_username]);
|
|
||||||
should contain_neutron_rootwrap_config('xenapi/xenapi_connection_password').with_value(params[:xenapi_connection_password]);
|
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
on_supported_os({
|
on_supported_os({
|
||||||
|
Reference in New Issue
Block a user