summaryrefslogtreecommitdiff
path: root/manifests
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2010-09-12 21:52:38 -0300
committerSilvio Rhatto <rhatto@riseup.net>2010-09-12 21:52:38 -0300
commit0a8736ad7c395e8eb6b205b5b86479d417bddfc1 (patch)
treeb5ddc12b0975dfbbf3114bfc238f8ec55218228d /manifests
parent593c80720d5d9a5fdd4baf3939ed98b7fc091429 (diff)
downloadpuppet-mail-0a8736ad7c395e8eb6b205b5b86479d417bddfc1.tar.gz
puppet-mail-0a8736ad7c395e8eb6b205b5b86479d417bddfc1.tar.bz2
Managing spamassassin
Diffstat (limited to 'manifests')
-rw-r--r--manifests/amavisd.pp2
-rw-r--r--manifests/spamassassin.pp16
-rw-r--r--manifests/system.pp1
3 files changed, 18 insertions, 1 deletions
diff --git a/manifests/amavisd.pp b/manifests/amavisd.pp
index 8617918..7c0bcb0 100644
--- a/manifests/amavisd.pp
+++ b/manifests/amavisd.pp
@@ -1,7 +1,7 @@
class mail::amavisd {
service { "amavisd":
ensure => running,
- require => Package['amavisd-new'],
+ require => [ Package['amavisd-new'], Service['clamav-daemon', 'spamassassin'] ],
}
service { "freshclam":
diff --git a/manifests/spamassassin.pp b/manifests/spamassassin.pp
new file mode 100644
index 0000000..a7d387b
--- /dev/null
+++ b/manifests/spamassassin.pp
@@ -0,0 +1,16 @@
+class mail::spamassassin {
+ file { '/etc/default/spamassassin':
+ ensure => present,
+ owner => root,
+ group => root,
+ mode => 0644,
+ source => "puppet:///modules/mail/spamassassin/default",
+ require => Package['spamassassin'],
+ }
+
+ service { 'spamassassin':
+ ensure => running,
+ enabled => true,
+ require => File['/etc/default/spamassassin'],
+ }
+}
diff --git a/manifests/system.pp b/manifests/system.pp
index bea848a..9a67de4 100644
--- a/manifests/system.pp
+++ b/manifests/system.pp
@@ -25,6 +25,7 @@ class mail::system {
include mail::amavisd
include mail::header_checks
include mail::clamav
+ include mail::spamassassin
# Virtual mail system
case $mail_virtual {