summaryrefslogtreecommitdiffstats
path: root/roles/MX/tasks/main.yml
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2013-12-18 14:34:10 +0100
committerGuilhem Moulin <guilhem@fripost.org>2015-06-07 02:51:31 +0200
commite98d17cca0011ead0bb89c7674a2209760dce59f (patch)
tree77be1b1e3ab980906e2d29ad0b665488edfea49c /roles/MX/tasks/main.yml
parentb51df24e3b1b64c17a3aac652b142e2082c77a26 (diff)
Remove the 'fripostLocalAlias' attribute.
Instead, we pretend that lists are valid users (via a match in the mailbox_transport_maps) but choose a different transport (with the same request in transport_maps). The advantage is that we get rid of the ugly hack for list transport… A minor drawback is that we now have two LDAP lookups instead of one for non local addresses (ie, everything but reserved addresses). Hopefully the requests are cached; but even if they aren't, querying a local LDAP server is supposed to be cheap.
Diffstat (limited to 'roles/MX/tasks/main.yml')
-rw-r--r--roles/MX/tasks/main.yml3
1 files changed, 1 insertions, 2 deletions
diff --git a/roles/MX/tasks/main.yml b/roles/MX/tasks/main.yml
index 1f5136a..de6924b 100644
--- a/roles/MX/tasks/main.yml
+++ b/roles/MX/tasks/main.yml
@@ -32,43 +32,42 @@
mode=0644
register: r
notify:
- Restart Postfix
- name: Create directory /etc/postfix-.../virtual
file: path=/etc/postfix-{{ postfix_instance[inst].name }}/virtual
state=directory
owner=root group=root
mode=0755
- name: Copy lookups tables
copy: src=etc/postfix/virtual/{{ item }}
dest=/etc/postfix-{{ postfix_instance[inst].name }}/virtual/{{ item }}
owner=root group=root
mode=0644
with_items:
- mailbox_domains.cf
- reserved_maps.pcre
- alias_maps.cf
- - lists_maps.cf
- alias_catchall_maps.cf
- mailbox_maps.cf
- - reserved_transport_maps
- transport_lists_maps.cf
+ - reserved_transport_maps
- name: Compile the Reserved Transport Maps
postmap: cmd=postalias instance={{ postfix_instance[inst].name }}
src=/etc/postfix-{{ postfix_instance[inst].name }}/virtual/reserved_transport_maps db=cdb
owner=root group=root
mode=0644
- name: Copy reserved-alias.pl
copy: src=usr/local/sbin/reserved-alias.pl
dest=/usr/local/sbin/reserved-alias.pl
owner=root group=root
mode=0755
- name: Start Postfix
service: name=postfix state=started
when: not r.changed
- meta: flush_handlers