diff options
| -rw-r--r-- | puppet/modules/site_postfix/manifests/mx.pp | 42 | 
1 files changed, 40 insertions, 2 deletions
| diff --git a/puppet/modules/site_postfix/manifests/mx.pp b/puppet/modules/site_postfix/manifests/mx.pp index 15449001..4bab7722 100644 --- a/puppet/modules/site_postfix/manifests/mx.pp +++ b/puppet/modules/site_postfix/manifests/mx.pp @@ -8,8 +8,46 @@ class site_postfix::mx {    $postfix_smtp_listen = 'all'    postfix::config { -    # just en example -    'delay_warning_time':     value => '4h'; +    'mydestination': +      value => "\$myorigin, localhost, localhost.\$mydomain, ${domain}"; +    'smtpd_recipient_restrictions': +      value => 'check_recipient_access hash:/etc/postfix/recipient,reject_unauth_destination'; +    'mailbox_size_limit': +      value => '0'; +    'home_mailbox': +      value => 'Maildir/'; +    'virtual_alias_maps': +      value => 'hash:/etc/postfix/virtual'; +  } + +  postfix::hash { '/etc/postfix/virtual': } +  postfix::hash { '/etc/postfix/recipient': } + +  # for now, accept all mail +  line {'deliver to vmail': +    file    => '/etc/postfix/recipient', +    line    => "@${domain} vmail", +    notify  => Exec['generate /etc/postfix/recipient.db'], +    require => Package['postfix'], +  } + +  postfix::virtual { "@${domain}": destination => 'vmail'; } +  #postfix::mailalias { 'vmail': recipient => 'vmail' } + +  user { 'vmail': +    ensure     => present, +    comment    => 'Leap Mailspool', +    home       => '/var/mail/vmail', +    shell      => '/bin/false', +    managehome => true, +  } + +  user { 'vmail': +    ensure     => present, +    comment    => 'Leap Mailspool', +    home       => '/var/mail/vmail', +    shell      => '/bin/false', +    managehome => true,    }    include ::postfix | 
