Bladeren bron

sympa integration

master
bovenliggende
commit
cd97758967
4 gewijzigde bestanden met toevoegingen van 39 en 12 verwijderingen
  1. +4
    -3
      defaults/main.yml
  2. +1
    -1
      tasks/main.yml
  3. +28
    -8
      templates/main.cf.j2
  4. +6
    -0
      templates/master.cf.j2

+ 4
- 3
defaults/main.yml Bestand weergeven

@@ -1,10 +1,10 @@
mailname: "{{inventory_hostname}}"

postfix_method: postfixadmin

postfix_smtp_service: true
postfix_submission_service: true
postfix_submission_service: false

postfix_with_postfixadmin: false
postfix_postfixadmin_mysql_host: localhost
postfix_postfixadmin_mysql_database: postfixadmin
postfix_postfixadmin_mysql_username: postfix
@@ -15,9 +15,10 @@ postfix_check_spamhaus: false
postfix_with_opendkim: false
postfix_with_opendmarc: false

postfix_virtual_transport: lmtp:unix:private/dovecot-lmtp
postfix_virtual_transport:

postfix_submission_service_smtpd_sasl_path: private/auth
postfix_with_dovecot_lmtp: false

postfix_smtps_service: true



+ 1
- 1
tasks/main.yml Bestand weergeven

@@ -63,7 +63,7 @@
when: postfix_with_opendmarc

- import_tasks: postfixadmin.yml
when: postfix_method == "postfixadmin"
when: postfix_with_postfixadmin

- name: check postfix configuration
command: postfix check


+ 28
- 8
templates/main.cf.j2 Bestand weergeven

@@ -46,7 +46,9 @@ smtp_tls_security_level = may
### transport configuration

relay_domains = hash:/etc/postfix/transport_maps
transport_maps = hash:/etc/postfix/transport_maps
transport_maps =
hash:/etc/postfix/transport_maps,



### rules and restricitons
@@ -128,23 +130,41 @@ virtual_alias_domains =

virtual_alias_maps =
hash:/etc/postfix/virtual_alias_maps,
{% if postfix_method == "postfixadmin" %}
{% if postfix_with_postfixadmin %}
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_maps.cf,
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_domain_maps.cf,
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_domain_catchall_maps.cf
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_domain_catchall_maps.cf,
{% endif %}
{% if postfix_with_sympa %}
hash:/etc/postfix/virtual.sympa,
{% endif %}

virtual_mailbox_domains =
hash:/etc/postfix/virtual_mailbox_domains,
{% if postfix_method == "postfixadmin" %}
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_domains_maps.cf
{% if postfix_with_postfixadmin %}
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_domains_maps.cf,
{% endif %}
{% if postfix_with_sympa %}
hash:/etc/postfix/domains.sympa,
{% endif %}

virtual_mailbox_maps =
hash:/etc/postfix/virtual_mailbox_maps,
{% if postfix_method == "postfixadmin" %}
{% if postfix_with_postfixadmin %}
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_mailbox_maps.cf,
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_domain_mailbox_maps.cf
proxy:mysql:/etc/postfix/postfixadmin-sql/mysql_virtual_alias_domain_mailbox_maps.cf,
{% endif %}
{% if postfix_with_sympa %}
hash:/etc/postfix/transport.sympa,
hash:/var/lib/sympa/transport,
hash:/etc/postfix/virtual.sympa,
{% endif %}

virtual_transport = {{postfix_virtual_transport}}
virtual_transport =
{% if postfix_with_sympa %}
hash:/etc/postfix/transport.sympa,
hash:/var/lib/sympa/transport,
{% endif %}
{% if postfix_with_dovecot_lmtp %}
lmtp:unix:private/dovecot-lmtp,
{% endif %}

+ 6
- 0
templates/master.cf.j2 Bestand weergeven

@@ -135,6 +135,12 @@ scalemail-backend unix - n n - 2 pipe
mailman unix - n n - - pipe
flags=FR user=list argv=/usr/lib/mailman/bin/postfix-to-mailman.py
${nexthop} ${user}
{% if postfix_with_sympa %}
sympa unix - n n - - pipe
flags=hqRu user=sympa argv=/usr/local/sympa/bin/queue ${nexthop}
sympabounce unix - n n - - pipe
flags=hqRu user=sympa argv=/usr/local/sympa/bin/bouncequeue ${nexthop}
{% endif %}

{% if postfix_check_spf %}
# spf


Laden…
Annuleren
Opslaan