2016-01-25 19:21:36 +01:00
|
|
|
---
|
|
|
|
|
|
|
|
- name: Install packages
|
|
|
|
apt: name={{ item }} state=present
|
|
|
|
with_items:
|
|
|
|
- postfix
|
2016-02-01 20:52:34 +01:00
|
|
|
- amavisd-new
|
|
|
|
- postgrey
|
|
|
|
- spamassassin
|
2016-01-25 19:21:36 +01:00
|
|
|
- dovecot-core
|
2016-02-01 20:52:34 +01:00
|
|
|
- dovecot-imapd
|
|
|
|
- dovecot-sieve
|
|
|
|
- dovecot-managesieved
|
2016-01-25 19:21:36 +01:00
|
|
|
- dovecot-ldap
|
2016-02-01 20:52:34 +01:00
|
|
|
tags: mail
|
2016-01-25 19:21:36 +01:00
|
|
|
|
|
|
|
- name: Configure postfix
|
2016-02-01 20:52:34 +01:00
|
|
|
template: src={{ item }} dest=/etc/postfix/{{ item }}
|
|
|
|
with_items:
|
|
|
|
- ldap-aliases.cf.j2
|
|
|
|
- ldap-virtual-maps.cf.j2
|
2016-01-25 19:21:36 +01:00
|
|
|
notify: restart postfix
|
2016-02-01 20:52:34 +01:00
|
|
|
tags: mail
|
2016-01-25 19:21:36 +01:00
|
|
|
|
2016-02-01 20:52:34 +01:00
|
|
|
- name: Start amavis
|
|
|
|
service: name=amavis state=started enabled=yes
|
|
|
|
tags: mail
|
2016-01-25 19:21:36 +01:00
|
|
|
|
|
|
|
- name: Start dovecot
|
|
|
|
service: name=dovecot state=started enabled=yes
|
2016-02-01 20:52:34 +01:00
|
|
|
tags: mail
|
2016-01-25 19:21:36 +01:00
|
|
|
|
|
|
|
- name: Start postfix
|
|
|
|
service: name=postfix state=started enabled=yes
|
2016-02-01 20:52:34 +01:00
|
|
|
tags: mail
|
|
|
|
|
|
|
|
- name: Start postgrey
|
|
|
|
service: name=postgrey state=started enabled=yes
|
|
|
|
tags: mail
|