Add class for busy mail machines
authorStephen Gran <steve@lobefin.net>
Mon, 16 Mar 2009 00:52:39 +0000 (00:52 +0000)
committerStephen Gran <steve@lobefin.net>
Mon, 16 Mar 2009 00:52:39 +0000 (00:52 +0000)
Signed-off-by: Stephen Gran <steve@lobefin.net>
modules/exim/manifests/init.pp

index 93ea0b6..265fda1 100644 (file)
@@ -92,3 +92,31 @@ class exim {
         refreshonly => true,
     }
 }
+
+class eximmx inherits exim {
+    package { "clamav-daemon": ensure => latest;
+              "postgrey": ensure => installed;
+    }
+
+    file {
+        "/etc/default/postgrey":
+          source  => "puppet:///exim/common/postgrey-default",
+          require => Package["postgrey"],
+          notify  => Exec["postgrey restart"]
+          ;
+        "/etc/clamav/clamd.conf":
+          source  => "puppet:///exim/common/clamd.conf",
+          require => Package["clamav-daemon"],
+          notify  => Exec["clamav-daemon restart"]
+          ;
+    }
+
+    exec { "clamav-daemon restart":
+        path        => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
+        refreshonly => true,
+    }
+    exec { "postgrey restart":
+        path        => "/etc/init.d:/usr/bin:/usr/sbin:/bin:/sbin",
+        refreshonly => true,
+    }
+}