Sfoglia il codice sorgente

make transport maps configurable

master
parent
commit
1f2839fae5
4 ha cambiato i file con 17 aggiunte e 1 eliminazioni
  1. +3
    -0
      handlers/main.yml
  2. +6
    -0
      tasks/main.yml
  3. +1
    -1
      templates/main.cf.j2
  4. +7
    -0
      templates/transport_maps.j2

+ 3
- 0
handlers/main.yml Vedi File

@@ -1,5 +1,8 @@
---

- name: postmap transport_maps
command: postmap /etc/postfix/transport_maps

- name: postmap virtual_alias_domains
command: postmap /etc/postfix/virtual_alias_domains



+ 6
- 0
tasks/main.yml Vedi File

@@ -23,6 +23,12 @@
dest: /etc/postfix/main.cf
notify: reload postfix

- name: postfix transport_maps
template:
src: transport_maps.j2
dest: /etc/postfix/transport_maps
notify: postmap transport_maps

- name: postfix virtual_alias_domains
template:
src: virtual_alias_domains.j2


+ 1
- 1
templates/main.cf.j2 Vedi File

@@ -44,7 +44,7 @@ smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

### transport configuration

#transport_maps = hash:/etc/postfix/transport
transport_maps = hash:/etc/postfix/transport_maps


### rules and restricitons


+ 7
- 0
templates/transport_maps.j2 Vedi File

@@ -0,0 +1,7 @@
{{ansible_managed|comment}}

{% if postfix_transport_maps is defined %}
{% for m in postfix_transport_maps %}
{{m.domain}} {{m.transport}}
{% endfor %}
{% endif %}

Loading…
Annulla
Salva