Add ulimit max-open-files param to puppet-hound
The upstream hound server is showing issues on the log about hitting max opened files, currently on OS default of 1024 files. This change allows setting the ulimit for open max files on the init script, defaulting to 2048. Change-Id: I283105dc0229e1e3f9ab56f0c8c3368581370d10
This commit is contained in:
parent
25c40f20a7
commit
ab87c7e377
|
@ -7,6 +7,7 @@ class hound (
|
|||
$manage_config = true,
|
||||
$serveradmin = "webmaster@${::fqdn}",
|
||||
$vhost_name = $::fqdn,
|
||||
$ulimit_max_open_files = 2048,
|
||||
) {
|
||||
|
||||
package { 'golang':
|
||||
|
@ -83,13 +84,13 @@ class hound (
|
|||
}
|
||||
|
||||
file { '/etc/init.d/hound':
|
||||
ensure => file,
|
||||
owner => root,
|
||||
group => root,
|
||||
mode => '0755',
|
||||
source => 'puppet:///modules/hound/hound.init',
|
||||
notify => Service['hound'],
|
||||
before => Service['hound'],
|
||||
ensure => file,
|
||||
owner => root,
|
||||
group => root,
|
||||
mode => '0755',
|
||||
content => template('hound/hound.init.erb'),
|
||||
notify => Service['hound'],
|
||||
before => Service['hound'],
|
||||
}
|
||||
|
||||
include ::httpd
|
||||
|
|
|
@ -24,6 +24,7 @@ PID=/var/run/${NAME}.pid
|
|||
|
||||
start () {
|
||||
echo -n "Start $NAME"
|
||||
ulimit -n <%= @ulimit_max_open_files %>
|
||||
$SSD --start --pidfile $PID --make-pidfile -u $USER -g $GROUP \
|
||||
-d $HOUND_HOME --background \
|
||||
--startas /bin/bash -- -c "exec $CMD_DIR/$CMD >>$LOG_FILE 2>&1"
|
Loading…
Reference in New Issue