postfix: Add relay support to specific domains
This commit is contained in:
parent
bf39708fac
commit
d55c77c30f
1 changed files with 14 additions and 0 deletions
14
roles/postfix/tasks/relay.yml
Normal file
14
roles/postfix/tasks/relay.yml
Normal file
|
@ -0,0 +1,14 @@
|
|||
---
|
||||
- name: listen to all interfaces
|
||||
lineinfile:
|
||||
path: /etc/postfix/main.cf
|
||||
state: absent
|
||||
regexp: "^#?inet_interfaces = .*"
|
||||
notify: restart postfix
|
||||
|
||||
- name: add relayed domains
|
||||
lineinfile:
|
||||
path: /etc/postfix/main.cf
|
||||
regexp: "^#?relay_domains = .*"
|
||||
line: "relay_domains = $mydestination, {{ relay_domains|join(',') }}"
|
||||
notify: restart postfix
|
Loading…
Add table
Reference in a new issue