From: Silvio Rhatto Date: Fri, 18 Jan 2013 21:03:18 +0000 (-0200) Subject: Cron job to restart puppetmaster shall exist just for mongrel X-Git-Url: https://gitweb.fluxo.info/?a=commitdiff_plain;h=28b0740d20ffca14c27d4cd3ab9978b5b5d50468;p=puppet-puppet.git Cron job to restart puppetmaster shall exist just for mongrel --- diff --git a/manifests/master/mongrel.pp b/manifests/master/mongrel.pp index eb96247..42b4050 100644 --- a/manifests/master/mongrel.pp +++ b/manifests/master/mongrel.pp @@ -28,6 +28,15 @@ class puppet::master::mongrel { require => [ Package['puppetmaster'], Package['mongrel'], Service['nginx'] ], } + # restart the master from time to time to avoid memory problems + # thanks to https://labs.riseup.net/code/projects/shared-puppet + file { "/etc/cron.d/puppetmaster": + source => "puppet://$server/modules/puppet/cron.d/puppetmaster", + owner => root, + group => root, + mode => 0644; + } + } class puppet::master::mongrel::disabled { @@ -41,4 +50,8 @@ class puppet::master::mongrel::disabled { enable => false, ensure => absent, } + + File['/etc/cron.d/puppetmaster'] + ensure => absent, + } } diff --git a/manifests/puppetmasterd.pp b/manifests/puppetmasterd.pp index 37a95ff..28311e1 100644 --- a/manifests/puppetmasterd.pp +++ b/manifests/puppetmasterd.pp @@ -134,15 +134,6 @@ class puppetmasterd { mode => 0700, } - # restart the master from time to time to avoid memory problems - # thanks to https://labs.riseup.net/code/projects/shared-puppet - file { "/etc/cron.d/puppetmaster": - source => "puppet://$server/modules/puppet/cron.d/puppetmaster", - owner => root, - group => root, - mode => 0644; - } - # and the script to the cron-job above file { "/usr/local/sbin/update-puppet-conf.sh": source => "puppet://$server/modules/puppet/update-puppet-conf.sh",