summaryrefslogtreecommitdiffstats
path: root/roles/MX/tasks
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2014-04-17 04:56:43 +0200
committerGuilhem Moulin <guilhem@fripost.org>2015-06-07 02:51:47 +0200
commite9e8ce2add2b7c020daa02228e506e7c02828c15 (patch)
tree88aee2a20e3c1961aa94769a4df4f236a21741bc /roles/MX/tasks
parent3d4b17515fc21dbb218873b23ff9272ca9474e8e (diff)
Decongestion potential bottlenecks on trivial_rewrite(8).
Which might be caused by slow LDAP lookups in transport_maps. Instead, we alias each addresses for which we want a custom transport to a dedicated "dummy" domain, and use a static (CDB) transport_maps to map said domains to their transport; the receiver can then use canonical(8) to restore the original envelope recipient. Since the alias resolution is performed by cleanup(8), which can run in parallel with other instances, it should decongestion bottlenecks under heavy loads. So far only the MX:es have been decongestioned. The list manager and the MDA should be treated as well.
Diffstat (limited to 'roles/MX/tasks')
-rw-r--r--roles/MX/tasks/main.yml5
1 files changed, 2 insertions, 3 deletions
diff --git a/roles/MX/tasks/main.yml b/roles/MX/tasks/main.yml
index e8dadb1..2670703 100644
--- a/roles/MX/tasks/main.yml
+++ b/roles/MX/tasks/main.yml
@@ -36,40 +36,39 @@
- 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 lookup tables
template: src=etc/postfix/virtual/{{ item }}.j2
dest=/etc/postfix-{{ postfix_instance[inst].name }}/virtual/{{ item }}
owner=root group=root
mode=0644
with_items:
- mailbox_domains.cf
- reserved_alias.pcre
- alias.cf
- mailbox.cf
- list.cf
- alias_domains.cf
- catchall.cf
- - transport_reserved_alias
- - transport_list.cf
+ - transport
- name: Compile the Reserved Transport Maps
postmap: instance={{ postfix_instance[inst].name }}
- src=/etc/postfix-{{ postfix_instance[inst].name }}/virtual/transport_reserved_alias db=cdb
+ src=/etc/postfix-{{ postfix_instance[inst].name }}/virtual/transport 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