summaryrefslogtreecommitdiffstats
path: root/roles/IMAP/handlers/main.yml
blob: c14468a93832ad5013428b76f8a16b5c8bbb3fd5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
---
- name: Restart Dovecot
  service: name=dovecot state=restarted

- name: Restart Postfix
  service: name=postfix state=restarted

- name: Reload Postfix
  service: name=postfix state=reloaded

- name: Compile Spamassassin rules
  sudo_user: debian-spamd
  # it might take a while...
  command: /usr/bin/sa-compile --quiet
           chdir=/var/lib/spamassassin/

- name: Restart Amavis
  service: name=amavis state=restarted

- name: Copy SQL tables for spamassassin
  copy: src=tmp/spamassassin.sql
        dest=/tmp/spamassassin.sql
        owner=root group=root
        mode=0600

- name: Create SQL tables for spamassassin
  # see https://svn.apache.org/repos/asf/spamassassin/trunk/sql/
  # for the original
  mysql_db: name=spamassassin state=import
            target=/tmp/spamassassin.sql
            encoding=latin1 collation=latin1_unicode_ci