1 public-inbox (server-side) installation
2 ---------------------------------------
4 This is for folks who want to setup their own public-inbox instance.
5 Clients should use normal git-clone/git-fetch, IMAP or NNTP clients
6 if they want to import mail into their personal inboxes.
8 public-inbox is developed on Debian GNU/Linux systems and will
9 never depend on packages outside of the "main" component of
10 the "stable" distribution, currently Debian 10.x ("buster"),
11 but older versions of Debian remain supported.
13 Most packages are available in other GNU/Linux distributions
16 TODO: this still needs to be documented better,
17 also see the scripts/ and sa_config/ directories in the source tree
22 public-inbox requires a number of other packages to access its full
23 functionality. The core tools are, of course:
25 * Git (1.8.0+, 2.6+ for writing v2 inboxes)
27 * DBD::SQLite (needed for IMAP, NNTP, message threading, and v2 inboxes)
29 To accept incoming mail into a public inbox, you'll likely want:
31 * MTA - postfix is recommended (for public-inbox-mda)
32 * SpamAssassin (spamc/spamd) (for public-inbox-watch/public-inbox-mda)
34 Beyond that, there is one non-standard Perl module required:
36 * URI::Escape deb: liburi-perl
39 (for HTML/Atom generation)
41 Plack and Date::Parse are optional as of public-inbox v1.3.0,
42 but required for older releases:
44 * Plack deb: libplack-perl
46 rpm: perl-Plack, perl-Plack-Test,
47 (for HTML/Atom generation)
49 - Date::Parse deb: libtimedate-perl
52 (for broken, mostly historical emails)
54 Where "deb" indicates package names for Debian-derived distributions,
55 "pkg" is for the FreeBSD package (maybe other common BSDs, too), and
56 "rpm" is for RPM-based distributions (only known to work on Fedora).
58 Numerous optional modules are likely to be useful as well:
60 - DBD::SQLite deb: libdbd-sqlite3-perl
63 (for v2, IMAP, NNTP, or gzipped mboxes)
65 - Search::Xapian or Xapian(.pm) deb: libsearch-xapian-perl
66 pkg: p5-Search-Xapian OR p5-Xapian
67 rpm: perl-Search-Xapian
68 (HTTP and IMAP search)
70 - Net::Server deb: libnet-server-perl
73 (for HTTP/IMAP/NNTP background daemons,
74 not needed as systemd services or
77 - Inline::C deb: libinline-c-perl
79 rpm: perl-Inline (or perl-Inline-C)
80 (speeds up process spawning on Linux,
81 see public-inbox-daemon(8))
83 - Email::Address::XS deb: libemail-address-xs-perl
84 pkg: pkg-Email-Address-XS
85 (correct parsing of tricky email
86 addresses, phrases and comments,
89 - Parse::RecDescent deb: libparse-recdescent-perl
90 pkg: p5-Parse-RecDescent
91 rpm: perl-ParseRecDescent
92 (optional, for public-inbox-imapd(1))
94 - BSD::Resource deb: libbsd-resource-perl
96 rpm: perl-BSD-Resource
97 (optional, for PSGI limiters
98 see public-inbox-config(5))
100 - Plack::Middleware::ReverseProxy deb: libplack-middleware-reverseproxy-perl
101 pkg: p5-Plack-Middleware-ReverseProxy
102 rpm: perl-Plack-Middleware-ReverseProxy
103 (ensures redirects are correct when running
104 behind nginx or Varnish)
106 * highlight deb: libhighlight-perl
107 (for syntax highlighting with coderepo)
109 * xapian-compact (tool) deb: xapian-tools
112 (optional, for public-inbox-compact(1))
114 - Linux::Inotify2 deb: liblinux-inotify2-perl
115 rpm: perl-Linux-Inotify2
116 (for public-inbox-watch and -imapd on Linux)
118 The following module is typically pulled in by dependencies listed
119 above, so there is no need to explicitly install them:
121 - DBI deb: libdbi-perl
124 (pulled in by DBD::SQLite)
126 Uncommonly needed modules (see HACKING for development-only modules):
128 - Socket6 deb: libsocket6-perl
131 (pulled in by SpamAssassin and Net::Server,
132 only necessary if using IPv6 with
133 Plack::Middleware::AccessLog or similar
136 - Crypt::CBC deb: libcrypt-cbc-perl
138 (for PublicInbox::Unsubscribe (rarely used))
140 standard MakeMaker installation (Perl)
141 --------------------------------------
143 To use MakeMaker, you need to ensure ExtUtils::MakeMaker is available.
144 This is typically installed with Perl, but RPM-based systems will likely
145 need to install the `perl-ExtUtils-MakeMaker' package.
147 Once the dependencies are installed, you should be able to build and
148 install the system (into /usr/local) with:
152 make test # see HACKING for faster tests for hackers
153 make install # root permissions may be needed
155 When installing Search::Xapian, make sure the underlying Xapian
156 installation is not affected by an index corruption bug:
158 https://bugs.debian.org/808610
160 For Debian 8.x (jessie), this means using Debian 8.5 or later.
162 public-inbox will never store unregeneratable data in Xapian
163 or any other search database we might use; Xapian corruption
164 will not destroy critical data.
166 See the public-inbox-overview(7) man page for the next steps once
167 the installation is complete.
169 The following required packages are part of the Perl standard
170 library. Debian-based distros put them in "libperl5.$MINOR" or
171 "perl-modules-5.$MINOR"; and FreeBSD puts them in "perl5".
172 RPM-based distros split them out into separate packages:
174 * Digest::SHA rpm: perl-Digest-SHA
175 * Data::Dumper rpm: perl-Data-Dumper
176 * Encode rpm: perl-Encode
177 * IO::Compress rpm: perl-IO-Compress
178 * Storable rpm: perl-Storable
179 * Text::ParseWords rpm: perl-Text-Parsewords
184 Copyright 2013-2021 all contributors <meta@public-inbox.org>
185 License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>