2022-03-08 19:42:28 +01:00
|
|
|
[Service]
|
|
|
|
ExecStartPre=/usr/sbin/postmap /etc/postfix/lmtp
|
|
|
|
ExecStartPre=/usr/sbin/postmap -F /etc/postfix/sni
|
2023-06-23 08:12:05 +02:00
|
|
|
{% for local in general.postfix.postfix_relay_authentifications %}
|
|
|
|
{% set user = local|normalize_family %}
|
|
|
|
{% set password = general.postfix['local_authentification_' + user]['local_authentification_password_' + user] %}
|
|
|
|
{% set ip = general.postfix['local_authentification_' + user]['postfix_relay_ip_' + user] %}
|
|
|
|
ExecStartPre=-/usr/bin/bash -c "echo {{ password }} | /usr/sbin/saslpasswd2 -u {{ ip }} {{ user }} -p"
|
|
|
|
{% endfor %}
|
2022-03-08 19:42:28 +01:00
|
|
|
ExecStartPre=/usr/bin/chown postfix: /etc/sasl2/sasldb2
|
|
|
|
PIDFile=/srv/postfix/spool/pid/master.pid
|