summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick Uiterwijk <patrick@puiterwijk.org>2017-08-04 18:20:08 +0200
committerPatrick Uiterwijk <patrick@puiterwijk.org>2017-08-04 18:20:17 +0200
commitcfab031a8adf5dc46d3d32ea4a0ccb19d7cc46ea (patch)
treef5e744b09cb6abab2be756dc89f35b4571f7769c
parent7a5346019bc92cb8f00f77f6a4e82a21e9ba8b37 (diff)
downloadansible-cfab031a8adf5dc46d3d32ea4a0ccb19d7cc46ea.tar.gz
ansible-cfab031a8adf5dc46d3d32ea4a0ccb19d7cc46ea.tar.xz
ansible-cfab031a8adf5dc46d3d32ea4a0ccb19d7cc46ea.zip
Deploy sender_access file
Signed-off-by: Patrick Uiterwijk <patrick@puiterwijk.org>
-rw-r--r--roles/base/tasks/postfix.yml17
1 files changed, 17 insertions, 0 deletions
diff --git a/roles/base/tasks/postfix.yml b/roles/base/tasks/postfix.yml
index 851bb8ab1..fb5bfae6e 100644
--- a/roles/base/tasks/postfix.yml
+++ b/roles/base/tasks/postfix.yml
@@ -30,6 +30,23 @@
- config
- base
+- name: Deploy sender_access file
+ copy: src="{{private}}/files/smtpd/sender_access" dest="/etc/postfix/sender_access
+ when: "{{postfix_group}} == 'smtp-mm'"
+ tags:
+ - postfix
+ - config
+ - base
+
+- name: Create sender_access hash
+ command: postmap hash:/etc/postfix/sender_access
+ changed_when: false
+ when: "{{postfix_group}} == 'smtp-mm'"
+ tags:
+ - postfix
+ - config
+ - base
+
- name: enable postfix to start
service: name=postfix state=started enabled=true
tags: