Merge "mariadb: Move generation of systemd drop-in to puppet-tripleo" into stable/newton

This commit is contained in:
Jenkins 2017-03-26 01:04:44 +00:00 committed by Gerrit Code Review
commit b97eb6b6bb
1 changed files with 21 additions and 6 deletions

View File

@ -26,6 +26,11 @@
# (Optional) The hostname of the node responsible for bootstrapping tasks
# Defaults to hiera('bootstrap_nodeid')
#
# [*generate_dropin_file_limit*]
# (Optional) Generate a systemd drop-in file to raise the file descriptor
# limit for the mysql service.
# Defaults to false
#
# [*manage_resources*]
# (Optional) Whether or not manage root user, root my.cnf, and service.
# Defaults to true
@ -45,12 +50,13 @@
# Defaults to hiera('step')
#
class tripleo::profile::base::database::mysql (
$bind_address = $::hostname,
$bootstrap_node = hiera('bootstrap_nodeid', undef),
$manage_resources = true,
$mysql_server_options = {},
$remove_default_accounts = true,
$step = hiera('step'),
$bind_address = $::hostname,
$bootstrap_node = hiera('bootstrap_nodeid', undef),
$generate_dropin_file_limit = false,
$manage_resources = true,
$mysql_server_options = {},
$remove_default_accounts = true,
$step = hiera('step'),
) {
if $::hostname == downcase($bootstrap_node) {
@ -96,6 +102,15 @@ class tripleo::profile::base::database::mysql (
service_enabled => $manage_resources,
remove_default_accounts => $remove_default_accounts,
}
if $generate_dropin_file_limit {
# Raise the mysql file limit
::systemd::service_limits { 'mariadb.service':
limits => {
'LimitNOFILE' => 16384
}
}
}
}
if $step >= 2 and $sync_db {