This commit is contained in:
Ludovic Cartier 2024-12-20 15:52:04 +01:00
parent ef7d95e82f
commit c48f671717
3 changed files with 20 additions and 0 deletions

View File

@ -11,5 +11,8 @@
- name: postmap sender relay - name: postmap sender relay
command: /usr/sbin/postmap /etc/postfix/sender_relay command: /usr/sbin/postmap /etc/postfix/sender_relay
- name: postmap transport maps
command: /usr/sbin/postmap /etc/postfix/transport
- name: postmap sasl passwd - name: postmap sasl passwd
command: /usr/sbin/postmap /etc/postfix/sasl_passwd command: /usr/sbin/postmap /etc/postfix/sasl_passwd

View File

@ -37,6 +37,18 @@
- restart postfix - restart postfix
when: postfix_sender_relay is defined when: postfix_sender_relay is defined
- name: postfix | transport maps
template:
src: transport.j2
dest: /etc/postfix/transport
owner: root
group: root
mode: 0644
notify:
- postmap transport
- restart postfix
when: postfix_transport_maps is defined
- name: postfix | sasl passwd - name: postfix | sasl passwd
template: template:
src: sasl_passwd.j2 src: sasl_passwd.j2

5
templates/transport.j2 Normal file
View File

@ -0,0 +1,5 @@
{% if postfix_transport_maps is defined %}
{% for map in postfix_transport_maps %}
{{ map }}
{% endfor %}
{% endif %}