]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Using postfix instead of postfix::mta
authorSilvio Rhatto <rhatto@riseup.net>
Sat, 29 May 2010 22:39:38 +0000 (19:39 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sat, 29 May 2010 22:39:38 +0000 (19:39 -0300)
manifests/mail.pp

index 089ae0f9db5c74d6f1e325cdec49ee9ddfa36b6f..1771f571bd82b5a87a7272fa949af2e32200e965 100644 (file)
@@ -1,12 +1,11 @@
 class nodo::mail {
   # Class for mail nodes
   $mail_delivery         = "postfix"
-  $postfix_relayhost     = "$domain"
   $postfix_smtp_listen   = "$ipaddress"
   $postfix_mydestination = '$myhostname, $mydomain, localhost.$mydomain, localhost'
 
   include nodo::vserver
-  include postfix::mta
+  include postfix
   include database
   include ssl::mail
 
@@ -33,8 +32,23 @@ class nodo::mail {
   } 
 
   # Postfix configuration
-  postfix::config { "myhostname":      value  => "$fqdn" }
-  postfix::config { "mailbox_command": value  => '/usr/bin/maildrop -d ${USER}' }
+  postfix::config {
+    "mydomain":           value => "$domain";
+    "myhostname":         value => "$fqdn";
+    "mydestination":      value => $postfix_mydestination;
+    "mynetworks":         value => "127.0.0.0/8";
+    "virtual_alias_maps": value => "hash:/etc/postfix/virtual";
+    "transport_maps":     value => "hash:/etc/postfix/transport";
+    "mailbox_command":    value => '/usr/bin/maildrop -d ${USER}';
+  }
+
+  postfix::hash { "/etc/postfix/virtual":
+    ensure => present,
+  }
+
+  postfix::hash { "/etc/postfix/transport":
+    ensure => present,
+  }
 
   # SASL
   postfix::config { "smtpd_sasl_auth_enable":          value => 'yes' }