]> gitweb.fluxo.info Git - puppet-puppet.git/commitdiff
Cron job to restart puppetmaster shall exist just for mongrel
authorSilvio Rhatto <rhatto@riseup.net>
Fri, 18 Jan 2013 21:03:18 +0000 (19:03 -0200)
committerSilvio Rhatto <rhatto@riseup.net>
Fri, 18 Jan 2013 21:03:18 +0000 (19:03 -0200)
manifests/master/mongrel.pp
manifests/puppetmasterd.pp

index eb96247559de5df04cae321c39f5d9b050c93666..42b405035d7a788f431acf26b1e4a1356a9a721f 100644 (file)
@@ -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,
+  }
 }
index 37a95fff224a13cedae18e7d70719840210181ef..28311e18950d1fbffbaa83f959973cf283b4989a 100644 (file)
@@ -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",