aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2018-05-05 12:44:51 +0800
committerAaron LI <aly@aaronly.me>2018-05-05 12:44:51 +0800
commit7a1b276f7b2c9478e28c16bb18e3095bd4b49e15 (patch)
tree31fd91b12aaa0601f36840f8d9213f1f43c4080c
parentb01d6d0711e08685f4f95e22d9e5a85ba98c8f72 (diff)
downloadansible-dfly-vps-7a1b276f7b2c9478e28c16bb18e3095bd4b49e15.tar.bz2
mail/dovecot: change sieve directory ownership
-rw-r--r--roles/mail/files/sieve/README1
-rw-r--r--roles/mail/tasks/main.yml9
2 files changed, 3 insertions, 7 deletions
diff --git a/roles/mail/files/sieve/README b/roles/mail/files/sieve/README
index b004418..302630b 100644
--- a/roles/mail/files/sieve/README
+++ b/roles/mail/files/sieve/README
@@ -12,6 +12,7 @@ NOTE:
write permission for the caller process:
$ sievec before.d
$ sievec after.d
+* Or change the directory's ownership to be "vmail:vmail".
See:
* https://wiki.dovecot.org/Pigeonhole/Sieve
diff --git a/roles/mail/tasks/main.yml b/roles/mail/tasks/main.yml
index 72debac..81afd0a 100644
--- a/roles/mail/tasks/main.yml
+++ b/roles/mail/tasks/main.yml
@@ -83,13 +83,8 @@
copy:
src: sieve/ # trailing '/' -> directory contents
dest: /usr/local/etc/dovecot/sieve/
- tags: dovecot
-
-- name: dovecot - compile sieve filters
- command: >
- find /usr/local/etc/dovecot/sieve/
- -name '*.sieve'
- -exec sievec '{}' ';'
+ owner: "{{ mail.vuser.name }}"
+ group: "{{ mail.vuser.name }}"
tags: dovecot
- name: dovecot - generate passdb and userdb