Update to trixie

This commit is contained in:
ibu ☉ radempa 2026-03-22 13:09:26 +01:00
parent 3686d35108
commit fbfb04717a
48 changed files with 914 additions and 2216 deletions

View file

@ -0,0 +1,3 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
See sieve_before/README; sieve filters in this directory are run after the user's scripts.

View file

@ -0,0 +1,9 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
require ["fileinto","mailbox"];
if header :contains "X-Spam" "Yes" {
fileinto :create "Junk";
stop;
}

View file

@ -0,0 +1,40 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
Sieve scripts that will be run before user scripts.
Don't forget to compile the script with
sievec /etc/dovecot/sieve_before/{name}.sieve
and
chown mailstore: /etc/dovecot/sieve_before/{name}.*
You may use regular Sieve extensions, but also Dovecot-specific Sieve extensions,
cf. https://wiki2.dovecot.org/Pigeonhole/Sieve .
(Note: We made vnd.dovecot.{pipe,filter,execute} available only in the global context,
they cannot be used by users.)
Example:
require ["vnd.dovecot.filter", "vnd.dovecot.execute", "variables", "envelope", "subaddress"];
if execute :output "out" :pipe "copy_to_matrix" {
filter "test" "${out}";
}
if envelope :matches :detail "to" "*" {
set "x" "${1}";
}
filter "test" "${x}";
if envelope :matches :user "to" "*" {
set "y" "${1}";
}
filter "test" "${y}";

View file

@ -0,0 +1,13 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
Execute is useful for conditions
Take care to not output a newline after the result!
Example:
#!/bin/bash
d=$(/bin/date +%s)
echo -n $d
exit 0

View file

@ -0,0 +1,15 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
A filter accepts a mail as input, modifies it and outputs the result.
Note: You cannot have side-effects like putting something into /tmp.
Example:
#!/bin/bash
echo "X-Test: $(date) $1"
cat

View file

@ -0,0 +1,8 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
require ["vnd.dovecot.pipe", "copy", "imapsieve", "variables"];
if string "${mailbox}" "Trash" {
stop;
}
pipe :copy "rspamd-learn-ham.sh";

Binary file not shown.

View file

@ -0,0 +1,5 @@
# THIS FILE IS CONTROLLED BY ANSIBLE - DO NOT CHANGE IN DEPLOYMENT!
require ["vnd.dovecot.pipe", "copy", "imapsieve"];
pipe :copy "rspamd-learn-spam.sh";

Binary file not shown.

View file

@ -0,0 +1,3 @@
#!/bin/sh
/usr/bin/rspamc learn_ham
exit 0

View file

@ -0,0 +1,3 @@
#!/bin/sh
/usr/bin/rspamc learn_spam
exit 0