diff options
author | varac <varacanero@zeromail.org> | 2015-12-01 11:13:14 +0100 |
---|---|---|
committer | varac <varacanero@zeromail.org> | 2015-12-01 11:13:14 +0100 |
commit | b1875e4143713ee007ce6ceedeef132273a16163 (patch) | |
tree | 1db97274b23999fe7cebf5f39196d1413a9dba41 | |
parent | 53572a8934fe5b0a3a567cdec10664f288923739 (diff) | |
parent | 6751268f0ff2002a8aa5bf56d59027e636ccafa3 (diff) |
Merge remote-tracking branch 'shared/master' into leap_master
-rw-r--r-- | README.md (renamed from README) | 15 | ||||
-rw-r--r-- | manifests/init.pp | 8 | ||||
-rw-r--r-- | templates/master.cf.debian-7.erb | 26 | ||||
-rw-r--r-- | templates/master.cf.debian-8.erb | 22 | ||||
-rw-r--r-- | templates/master.cf.debian-sid.erb | 26 |
5 files changed, 54 insertions, 43 deletions
@@ -1,4 +1,5 @@ -= Postfix Puppet module +Postfix Puppet module +===================== This module will help install and configure postfix. @@ -11,9 +12,19 @@ This module needs: !! Upgrade Notice (01/2013) !! This module now uses parameterized classes, where it used global variables -before. So please whatch out before pulling, you need to change the +before. So please whatch out before pulling, you need to change the class declarations in your manifest ! +Issues +------ + +- Debian wheezy hosts (or below): If you get this error msg: + + "Could not find template 'postfix/master.cf.debian-.erb' at /ssrv/leap/puppet/modules/postfix/manifests/init.pp:158 on node rew07plain1.rewire.org" + + you need to use the facter package from wheezy-backports instead of the wheezy one. See https://gitlab.com/shared-puppet-modules-group/postfix/merge_requests/6#note_1892207 for more details. + + Deprecation notice ------------------ diff --git a/manifests/init.pp b/manifests/init.pp index adab904..85ff5af 100644 --- a/manifests/init.pp +++ b/manifests/init.pp @@ -62,7 +62,7 @@ class postfix( case $::operatingsystem { RedHat, CentOS: { - case $::lsbmajdistrelease { + case $::operatingsystemmajrelease { "4": { $postfix_seltype = "etc_t" } "5": { $postfix_seltype = "postfix_etc_t" } default: { $postfix_seltype = undef } @@ -101,7 +101,7 @@ class postfix( include postfix::virtual_regexp } - package { 'mailx': + package { ["postfix", "mailx"]: ensure => installed } @@ -126,7 +126,7 @@ class postfix( file { "/etc/mailname": ensure => present, - content => "${mailname}\n", + content => "${fqdn}\n", seltype => $postfix_seltype, } @@ -156,7 +156,7 @@ class postfix( content => $::operatingsystem ? { Redhat => template("postfix/master.cf.redhat5.erb"), CentOS => template("postfix/master.cf.redhat5.erb"), - Debian => template("postfix/master.cf.debian-${::lsbmajdistrelease}.erb"), + Debian => template("postfix/master.cf.debian-${::operatingsystemmajrelease}.erb"), Ubuntu => template("postfix/master.cf.debian-etch.erb"), }, seltype => $postfix_seltype, diff --git a/templates/master.cf.debian-7.erb b/templates/master.cf.debian-7.erb index cc4bbf0..7b653fb 100644 --- a/templates/master.cf.debian-7.erb +++ b/templates/master.cf.debian-7.erb @@ -8,25 +8,25 @@ # service type private unpriv chroot wakeup maxproc command + args # (yes) (yes) (yes) (never) (100) # ========================================================================== -<% if smtp_listen == 'all' %>smtp inet n - - - - smtpd -<% else %><%= smtp_listen %>:smtp inet n - - - - smtpd<% end %> +<% if @smtp_listen == 'all' %>smtp inet n - - - - smtpd +<% else %><%= @smtp_listen %>:smtp inet n - - - - smtpd<% end %> #smtp inet n - - - 1 postscreen #smtpd pass - - - - - smtpd #dnsblog unix - - - - 0 dnsblog #tlsproxy unix - - - - 0 tlsproxy -<% if use_submission == 'yes' %>submission inet n - - - - smtpd +<% if @use_submission == 'yes' %>submission inet n - - - - smtpd -o smtpd_tls_security_level=encrypt -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o milter_macro_daemon_name=ORIGINATING <% end %> -<% if use_smtps == 'yes' %>smtps inet n - - - - smtpd +<% if @use_smtps == 'yes' %>smtps inet n - - - - smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o milter_macro_daemon_name=ORIGINATING <% end %> -#628 inet n - - - - qmqpd +#628 inet n - - - - qmqpd pickup fifo n - - 60 1 pickup cleanup unix n - - - 0 cleanup qmgr fifo n - n 300 1 qmgr @@ -114,7 +114,7 @@ mailman unix - n n - - pipe flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py ${nexthop} ${user} -<% if use_amavisd == 'yes' %> +<% if @use_amavisd == 'yes' %> amavis unix - - - - 2 smtp -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes @@ -133,25 +133,25 @@ amavis unix - - - - 2 smtp -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks -o smtpd_bind_address=127.0.0.1 <% end %> -<% if use_dovecot_lda == 'yes' %> +<% if @use_dovecot_lda == 'yes' %> dovecot unix - n n - - pipe - flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -f ${sender} -d ${user}@${nexthop} -n -m ${extension} + flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -f ${sender} -d ${user}@${nexthop} -n -m ${extension} <% end %> -<% if use_schleuder == 'yes' %> +<% if @use_schleuder == 'yes' %> schleuder unix - n n - - pipe flags=DRhu user=schleuder argv=/usr/bin/schleuder ${user} <% end %> -<% if use_sympa == 'yes' %> +<% if @use_sympa == 'yes' %> sympa unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/queue ${recipient} sympabounce unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/bouncequeue ${user} <% end %> -<% if use_mlmmj == 'yes' %> +<% if @use_mlmmj == 'yes' %> mlmmj unix - n n - - pipe flags=DORhu user=mlmmj argv=/usr/bin/mlmmj-recieve -F -L /var/spool/mlmmj/$nexthop/ <%- end -%> -<%- unless mastercf_tail.to_s.empty? then -%> -<%= mastercf_tail %> +<%- unless @mastercf_tail.to_s.empty? then -%> +<%= @mastercf_tail %> <%- end -%> diff --git a/templates/master.cf.debian-8.erb b/templates/master.cf.debian-8.erb index a4c39b7..7b653fb 100644 --- a/templates/master.cf.debian-8.erb +++ b/templates/master.cf.debian-8.erb @@ -8,19 +8,19 @@ # service type private unpriv chroot wakeup maxproc command + args # (yes) (yes) (yes) (never) (100) # ========================================================================== -<% if smtp_listen == 'all' %>smtp inet n - - - - smtpd -<% else %><%= smtp_listen %>:smtp inet n - - - - smtpd<% end %> +<% if @smtp_listen == 'all' %>smtp inet n - - - - smtpd +<% else %><%= @smtp_listen %>:smtp inet n - - - - smtpd<% end %> #smtp inet n - - - 1 postscreen #smtpd pass - - - - - smtpd #dnsblog unix - - - - 0 dnsblog #tlsproxy unix - - - - 0 tlsproxy -<% if use_submission == 'yes' %>submission inet n - - - - smtpd +<% if @use_submission == 'yes' %>submission inet n - - - - smtpd -o smtpd_tls_security_level=encrypt -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o milter_macro_daemon_name=ORIGINATING <% end %> -<% if use_smtps == 'yes' %>smtps inet n - - - - smtpd +<% if @use_smtps == 'yes' %>smtps inet n - - - - smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject @@ -114,7 +114,7 @@ mailman unix - n n - - pipe flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py ${nexthop} ${user} -<% if use_amavisd == 'yes' %> +<% if @use_amavisd == 'yes' %> amavis unix - - - - 2 smtp -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes @@ -133,25 +133,25 @@ amavis unix - - - - 2 smtp -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks -o smtpd_bind_address=127.0.0.1 <% end %> -<% if use_dovecot_lda == 'yes' %> +<% if @use_dovecot_lda == 'yes' %> dovecot unix - n n - - pipe flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -f ${sender} -d ${user}@${nexthop} -n -m ${extension} <% end %> -<% if use_schleuder == 'yes' %> +<% if @use_schleuder == 'yes' %> schleuder unix - n n - - pipe flags=DRhu user=schleuder argv=/usr/bin/schleuder ${user} <% end %> -<% if use_sympa == 'yes' %> +<% if @use_sympa == 'yes' %> sympa unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/queue ${recipient} sympabounce unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/bouncequeue ${user} <% end %> -<% if use_mlmmj == 'yes' %> +<% if @use_mlmmj == 'yes' %> mlmmj unix - n n - - pipe flags=DORhu user=mlmmj argv=/usr/bin/mlmmj-recieve -F -L /var/spool/mlmmj/$nexthop/ <%- end -%> -<%- unless mastercf_tail.to_s.empty? then -%> -<%= mastercf_tail %> +<%- unless @mastercf_tail.to_s.empty? then -%> +<%= @mastercf_tail %> <%- end -%> diff --git a/templates/master.cf.debian-sid.erb b/templates/master.cf.debian-sid.erb index d5a5a14..7b653fb 100644 --- a/templates/master.cf.debian-sid.erb +++ b/templates/master.cf.debian-sid.erb @@ -8,25 +8,25 @@ # service type private unpriv chroot wakeup maxproc command + args # (yes) (yes) (yes) (never) (100) # ========================================================================== -<% if smtp_listen == 'all' %>smtp inet n - - - - smtpd -<% else %><%= smtp_listen %>:smtp inet n - - - - smtpd<% end %> +<% if @smtp_listen == 'all' %>smtp inet n - - - - smtpd +<% else %><%= @smtp_listen %>:smtp inet n - - - - smtpd<% end %> #smtp inet n - - - 1 postscreen #smtpd pass - - - - - smtpd #dnsblog unix - - - - 0 dnsblog #tlsproxy unix - - - - 0 tlsproxy -<% if use_submission == 'yes' %>submission inet n - - - - smtpd +<% if @use_submission == 'yes' %>submission inet n - - - - smtpd -o smtpd_tls_security_level=encrypt -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o milter_macro_daemon_name=ORIGINATING <% end %> -<% if use_smtps == 'yes' %>smtps inet n - - - - smtpd +<% if @use_smtps == 'yes' %>smtps inet n - - - - smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o milter_macro_daemon_name=ORIGINATING <% end %> -#628 inet n - - - - qmqpd +#628 inet n - - - - qmqpd pickup fifo n - - 60 1 pickup cleanup unix n - - - 0 cleanup qmgr fifo n - n 300 1 qmgr @@ -114,7 +114,7 @@ mailman unix - n n - - pipe flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py ${nexthop} ${user} -<% if use_amavisd == 'yes' %> +<% if @use_amavisd == 'yes' %> amavis unix - - - - 2 smtp -o smtp_data_done_timeout=1200 -o smtp_send_xforward_command=yes @@ -133,25 +133,25 @@ amavis unix - - - - 2 smtp -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks -o smtpd_bind_address=127.0.0.1 <% end %> -<% if use_dovecot_lda == 'yes' %> +<% if @use_dovecot_lda == 'yes' %> dovecot unix - n n - - pipe - flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -d ${recipient} + flags=DRhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -f ${sender} -d ${user}@${nexthop} -n -m ${extension} <% end %> -<% if use_schleuder == 'yes' %> +<% if @use_schleuder == 'yes' %> schleuder unix - n n - - pipe flags=DRhu user=schleuder argv=/usr/bin/schleuder ${user} <% end %> -<% if use_sympa == 'yes' %> +<% if @use_sympa == 'yes' %> sympa unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/queue ${recipient} sympabounce unix - n n - - pipe flags=R user=sympa argv=/usr/lib/sympa/bin/bouncequeue ${user} <% end %> -<% if use_mlmmj == 'yes' %> +<% if @use_mlmmj == 'yes' %> mlmmj unix - n n - - pipe flags=DORhu user=mlmmj argv=/usr/bin/mlmmj-recieve -F -L /var/spool/mlmmj/$nexthop/ <%- end -%> -<%- unless mastercf_tail.to_s.empty? then -%> -<%= mastercf_tail %> +<%- unless @mastercf_tail.to_s.empty? then -%> +<%= @mastercf_tail %> <%- end -%> |