]> Sergey Matveev's repositories - public-inbox.git/blob - examples/README.unsubscribe
3e80e838c4d2a733cdf2686fd023c09a6faaefdb
[public-inbox.git] / examples / README.unsubscribe
1 Unsubscribe endpoints for mlmmj users (and possibly Mailman, too)
2
3 * examples/unsubscribe.milter filters outgoing messages
4   and appends an HTTPS URL to the List-Unsubscribe header.
5   This List-Unsubscribe header should point to the PSGI
6   described below.
7   Currently, this is only active for a whitelist of test
8   addresses in /etc/unsubscribe-milter.whitelist
9   with one email address per line.
10
11 * examples/unsubscribe.psgi is a PSGI which needs to run
12   as the mlmmj user with permission to run mlmmj-unsub.
13   This depends on the PublicInbox::Unsubscribe module
14   which may be extracted from the rest of public-inbox.
15   It is strongly recommended to NOT run the rest of the
16   public-inbox WWW code in the same process as this PSGI.
17   (The public-inbox WWW code will never need write
18    permissions to anything besides stderr).
19
20 * Both the .milter and .psgi examples are bundled with
21   systemd service and socket activation examples.
22   AFAIK no other PSGI server besides public-inbox-httpd
23   supports systemd socket activation.
24
25 To wire up the milter for postfix, I use the following
26 in /etc/postfix/main.cf:
27
28   # Milter configuration
29   milter_default_action = accept
30   milter_protocol = 2
31
32   # other milters may be chained here (e.g. opendkim)
33   # chroot users will need to adjust this path
34   smtpd_milters = local:/var/spool/postfix/unsubscribe/unsubscribe.sock
35
36   # This is not needed for mlmmj since mlmmj uses SMTP:
37   # non_smtpd_milters = local:/var/spool/postfix/unsubscribe/unsubscribe.sock
38
39 Copyright (C) 2016-2021 all contributors <meta@public-inbox.org>
40 License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>