This commit is contained in:
mwiegand 2021-10-18 22:29:01 +02:00
parent 7b3c1ece8d
commit b4f1145b6a
4 changed files with 18 additions and 5 deletions

View file

@ -116,7 +116,7 @@ plugin {
sieve_plugins = sieve_imapsieve sieve_extprograms sieve_plugins = sieve_imapsieve sieve_extprograms
sieve_dir = /var/vmail/sieve/%u/ sieve_dir = /var/vmail/sieve/%u/
sieve = /var/vmail/sieve/%u.sieve sieve = /var/vmail/sieve/%u.sieve
sieve_pipe_bin_dir = /var/vmail/sieve/ sieve_pipe_bin_dir = /var/vmail/sieve/bin/
sieve_extensions = +vnd.dovecot.pipe sieve_extensions = +vnd.dovecot.pipe
sieve_after = /var/vmail/sieve/global/spam-to-folder.sieve sieve_after = /var/vmail/sieve/global/spam-to-folder.sieve

View file

@ -4,4 +4,4 @@ if string "${mailbox}" "Trash" {
stop; stop;
} }
pipe :copy "rspamd-learn-ham.sh"; pipe :copy "learn-ham.sh";

View file

@ -1,3 +1,3 @@
require ["vnd.dovecot.pipe", "copy", "imapsieve"]; require ["vnd.dovecot.pipe", "copy", "imapsieve"];
pipe :copy "rspamd-learn-spam.sh"; pipe :copy "learn-spam.sh";

View file

@ -29,6 +29,10 @@ directories = {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
}, },
'/var/vmail/sieve/bin': {
'owner': 'vmail',
'group': 'vmail',
},
} }
files = { files = {
@ -71,12 +75,18 @@ files = {
'/var/vmail/sieve/global/spam-to-folder.sieve': { '/var/vmail/sieve/global/spam-to-folder.sieve': {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
'triggers': {
'svc_systemd:dovecot:restart',
},
}, },
'/var/vmail/sieve/global/learn-ham.sieve': { '/var/vmail/sieve/global/learn-ham.sieve': {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
'triggers': {
'svc_systemd:dovecot:restart',
},
}, },
'/var/vmail/sieve/global/learn-ham.sh': { '/var/vmail/sieve/bin/learn-ham.sh': {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
'mode': '550', 'mode': '550',
@ -84,8 +94,11 @@ files = {
'/var/vmail/sieve/global/learn-spam.sieve': { '/var/vmail/sieve/global/learn-spam.sieve': {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
'triggers': {
'svc_systemd:dovecot:restart',
},
}, },
'/var/vmail/sieve/global/learn-spam.sh': { '/var/vmail/sieve/bin/learn-spam.sh': {
'owner': 'vmail', 'owner': 'vmail',
'group': 'vmail', 'group': 'vmail',
'mode': '550', 'mode': '550',