aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ansible/roles/postfix/tasks/main.yml2
-rw-r--r--ansible/roles/postfix/templates/ldap/ldap-group-aliases.cf.j211
2 files changed, 13 insertions, 0 deletions
diff --git a/ansible/roles/postfix/tasks/main.yml b/ansible/roles/postfix/tasks/main.yml
index 1c00777..fdf4612 100644
--- a/ansible/roles/postfix/tasks/main.yml
+++ b/ansible/roles/postfix/tasks/main.yml
@@ -48,6 +48,8 @@
filename: ldap-uid.cf
- template: ldap/ldap-relay-recipients.cf.j2
filename: ldap-relay-recipients.cf
+ - template: ldap/ldap-group-aliases.cf.j2
+ filename: ldap-group-aliases.cf
tags:
- role::postfix
notify:
diff --git a/ansible/roles/postfix/templates/ldap/ldap-group-aliases.cf.j2 b/ansible/roles/postfix/templates/ldap/ldap-group-aliases.cf.j2
new file mode 100644
index 0000000..9965e0d
--- /dev/null
+++ b/ansible/roles/postfix/templates/ldap/ldap-group-aliases.cf.j2
@@ -0,0 +1,11 @@
+# Ansible Managed
+
+server_host = {{ postfix_bind_server }}
+bind = yes
+bind_dn = {{ postfix_bind_user }}
+bind_pw = {{ postfix_bind_password }}
+search_base = cn=groups,cn=accounts,dc=box,dc=pydis,dc=wtf
+query_filter = (cn=%u)
+special_result_attribute = member
+result_attribute = mail
+version = 3