replace validate_legacy with proper data types
the validate_legacy function is marked for deprecation in v9.0.0 from puppetlabs-stdlib. This also adds validations about some boolean parameters. Change-Id: I57e0321eab18b66c00e364bb3b4346bb06591286
This commit is contained in:
parent
bc209cda05
commit
1f273d3b4e
@ -104,14 +104,14 @@
|
||||
# Defaults to $facts['os_service_default'].
|
||||
#
|
||||
class trove::api(
|
||||
$manage_service = true,
|
||||
Boolean $manage_service = true,
|
||||
$service_name = $::trove::params::api_service_name,
|
||||
$package_ensure = 'present',
|
||||
$bind_host = $facts['os_service_default'],
|
||||
$bind_port = $facts['os_service_default'],
|
||||
$backlog = $facts['os_service_default'],
|
||||
$workers = $facts['os_workers'],
|
||||
$enabled = true,
|
||||
Boolean $enabled = true,
|
||||
$purge_config = false,
|
||||
$cert_file = false,
|
||||
$key_file = false,
|
||||
|
@ -33,8 +33,8 @@
|
||||
# Default: $facts['os_service_default']
|
||||
#
|
||||
class trove::conductor(
|
||||
$enabled = true,
|
||||
$manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
Boolean $manage_service = true,
|
||||
$package_ensure = 'present',
|
||||
$conductor_manager = 'trove.conductor.manager.Manager',
|
||||
$workers = $facts['os_workers'],
|
||||
|
@ -52,17 +52,13 @@
|
||||
# or Puppet catalog compilation will fail with duplicate resources.
|
||||
#
|
||||
class trove::config (
|
||||
$trove_config = {},
|
||||
$trove_guestagent_config = {},
|
||||
$trove_api_paste_ini = {},
|
||||
Hash $trove_config = {},
|
||||
Hash $trove_guestagent_config = {},
|
||||
Hash $trove_api_paste_ini = {},
|
||||
) {
|
||||
|
||||
include trove::deps
|
||||
|
||||
validate_legacy(Hash, 'validate_hash', $trove_config)
|
||||
validate_legacy(Hash, 'validate_hash', $trove_guestagent_config)
|
||||
validate_legacy(Hash, 'validate_hash', $trove_api_paste_ini)
|
||||
|
||||
create_resources('trove_config', $trove_config)
|
||||
create_resources('trove_guestagent_config', $trove_guestagent_config)
|
||||
create_resources('trove_api_paste_ini', $trove_api_paste_ini)
|
||||
|
@ -50,7 +50,7 @@
|
||||
# Defaults 'utf8_general_ci'.
|
||||
#
|
||||
class trove::db::mysql(
|
||||
$password,
|
||||
String[1] $password,
|
||||
$dbname = 'trove',
|
||||
$user = 'trove',
|
||||
$host = '127.0.0.1',
|
||||
@ -61,8 +61,6 @@ class trove::db::mysql(
|
||||
|
||||
include trove::deps
|
||||
|
||||
validate_legacy(String, 'validate_string', $password)
|
||||
|
||||
::openstacklib::db::mysql { 'trove':
|
||||
user => $user,
|
||||
password => $password,
|
||||
|
@ -25,7 +25,7 @@
|
||||
# Default to 'ALL'
|
||||
#
|
||||
class trove::db::postgresql(
|
||||
$password,
|
||||
String[1] $password,
|
||||
$dbname = 'trove',
|
||||
$user = 'trove',
|
||||
$encoding = undef,
|
||||
@ -34,8 +34,6 @@ class trove::db::postgresql(
|
||||
|
||||
include trove::deps
|
||||
|
||||
validate_legacy(String, 'validate_string', $password)
|
||||
|
||||
::openstacklib::db::postgresql { 'trove':
|
||||
password => $password,
|
||||
dbname => $dbname,
|
||||
|
@ -50,8 +50,8 @@
|
||||
define trove::generic_service(
|
||||
$package_name,
|
||||
$service_name,
|
||||
$enabled = false,
|
||||
$manage_service = true,
|
||||
Boolean $enabled = false,
|
||||
Boolean $manage_service = true,
|
||||
$package_ensure = 'present',
|
||||
) {
|
||||
|
||||
|
@ -91,8 +91,8 @@
|
||||
# Defaults to undef
|
||||
#
|
||||
class trove::guestagent(
|
||||
$enabled = false,
|
||||
$manage_service = true,
|
||||
Boolean $enabled = false,
|
||||
Boolean $manage_service = true,
|
||||
$package_ensure = 'present',
|
||||
$debug = $facts['os_service_default'],
|
||||
$log_file = '/var/log/trove/trove-guestagent.log',
|
||||
|
@ -270,7 +270,7 @@ class trove(
|
||||
$amqp_sasl_config_name = $facts['os_service_default'],
|
||||
$amqp_username = $facts['os_service_default'],
|
||||
$amqp_password = $facts['os_service_default'],
|
||||
$single_tenant_mode = false,
|
||||
Boolean $single_tenant_mode = false,
|
||||
$nova_compute_url = false,
|
||||
$rpc_response_timeout = $facts['os_service_default'],
|
||||
$control_exchange = 'trove',
|
||||
|
@ -47,8 +47,8 @@
|
||||
# Defaults to 'trove.taskmanager.manager.Manager'.
|
||||
#
|
||||
class trove::taskmanager(
|
||||
$enabled = true,
|
||||
$manage_service = true,
|
||||
Boolean $enabled = true,
|
||||
Boolean $manage_service = true,
|
||||
$guest_log_file = '/var/log/trove/trove-guestagent.log',
|
||||
$package_ensure = 'present',
|
||||
$guestagent_config_file = '/etc/trove/trove-guestagent.conf',
|
||||
|
Loading…
Reference in New Issue
Block a user