]> Sergey Matveev's repositories - public-inbox.git/blob - INSTALL
viewvcs: wire up syntax-highlighting for blobs
[public-inbox.git] / INSTALL
1 public-inbox (server-side) installation
2 ---------------------------------------
3
4 This is for folks who want to setup their own public-inbox instance.
5 Clients should use normal git-clone/git-fetch, or NNTP clients
6 if they want to import mail into their personal inboxes.
7
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 9.x ("stretch")
11
12 Most packages are available in other GNU/Linux distributions;
13 and FreeBSD support can happen.
14
15 TODO: this still needs to be documented better,
16 also see the scripts/ and sa_config/ directories in the source tree
17
18 Requirements
19 ------------
20
21 public-inbox requires a number of other packages to access its full
22 functionality.  The core tools are, of course:
23
24 * Git (1.8.0+, 2.6+ for writing v2 repositories)
25 * Perl 5.8+
26 * SQLite (needed for Xapian use)
27
28 To accept incoming mail into a public inbox, you'll likely want:
29
30 * MTA - postfix is recommended (for public-inbox-mda)
31 * SpamAssassin (spamc/spamd)   (for public-inbox-watch/public-inbox-mda)
32
33 Beyond that, there is a long list of Perl modules required, starting with:
34
35 * Date::Parse                   deb: libtimedate-perl
36                                 rpm: perl-Time-ParseDate
37
38 * Email::MIME                   deb: libemail-mime-perl
39                                 rpm: perl-Email-MIME
40
41 * Email::MIME::ContentType      deb: libemail-mime-contenttype-perl
42                                 rpm: perl-Email-MIME-ContentType
43
44 * Encode::MIME::Header          deb: libencode-perl
45                                 rpm: perl-Encode
46
47 * Plack                         deb: libplack-perl
48                                 rpm: perl-Plack, perl-Plack-Test,
49                                 (for HTML/Atom generation)
50
51 * URI::Escape                   deb: liburi-perl
52                                 rpm: perl-URI
53                                 (for HTML/Atom generation)
54
55 Where "deb" indicates package names for Debian-derived distributions and
56 "rpm" is for RPM-based distributions (only known to work on Fedora).
57
58 Numerous optional modules are likely to be useful as well:
59
60   - Search::Xapian             deb: libsearch-xapian-perl
61                                rpm: perl-Search-Xapian
62                                (for NNTP service or gzipped mbox over HTTP)
63
64   - IO::Compress::Gzip         deb: perl-modules (or libio-compress-perl)
65                                rpm: perl-PerlIO-gzip
66                                (for gzipped mbox over HTTP)
67
68   - DBI                        deb: libdbi-perl
69                                rpm: perl-DBI
70                                (for gzipped mbox over HTTP)
71
72   - DBD::SQLite                deb: libdbd-sqlite3-perl
73                                rpm: perl-DBD-SQLite
74                                (for NNTP service or gzipped mbox over HTTP)
75
76   - Danga::Socket              deb: libdanga-socket-perl
77                                rpm: perl-Danga-Socket
78                                (for bundled HTTP and NNTP servers)
79
80   - Net::Server                deb: libnet-server-perl
81                                rpm: perl-Net-Server
82                                (for HTTP/NNTP servers as standalone daemons,
83                                 not needed as systemd services)
84
85   - Filesys::Notify::Simple    deb: libfilesys-notify-simple-perl
86                                rpm: perl-Filesys-Notify-Simple
87                                (for public-inbox-watch)
88
89   - Inline::C[7]               deb: libinline-c-perl
90                                (speeds up spawning of git(1) on Linux
91                                 (see public-inbox-daemon(8))
92
93   - Plack::Middleware::ReverseProxy
94
95                                deb: libplack-middleware-reverseproxy-perl
96                                rpm: perl-Plack-Middleware-ReverseProxy
97                                (ensures redirects are correct when running
98                                 behind nginx or Varnish)
99
100   - Plack::Middleware::Deflater
101
102                                deb: libplack-middleware-deflater-perl
103                                rpm: perl-Plack-Middleware-Deflater
104                                (saves bandwidth on responses)
105
106   - Socket6                    deb: libsocket6-perl
107                                rpm: perl-Socket6
108                                (pulled in by SpamAssassin and Net::Server,
109                                 only necessary if using IPv6 with
110                                 Plack::Middleware::AccessLog or similar)
111
112 On Fedora systems, you'll probably also end up wanting
113 perl-Test-HTTP-Server-Simple, perl-Devel-Peek, and perl-IPC-Run to run the
114 test suite.  On Debian systems, libxml-feed-perl and libipc-run-perl
115 will aid in running the test suite (XML::Feed and IPC::Run respectively,
116 on CPAN).
117
118 standard MakeMaker installation (Perl)
119 --------------------------------------
120
121 Once the dependencies are installed, you should be able to build and
122 install the system (into /usr/local) with:
123
124         perl Makefile.PL
125         make
126         make test
127         make install # root permissions may be needed
128
129 When installing Search::Xapian, make sure the underlying Xapian
130 installation is not affected by an index corruption bug:
131
132         https://bugs.debian.org/808610
133
134 For Debian 8.x (jessie), this means using Debian 8.5 or later.
135
136 public-inbox will never store unregeneratable data in Xapian
137 or any other search database we might use; Xapian corruption
138 will not destroy critical data.
139
140 See the public-inbox-overview(7) man page for the next steps once the
141 installation is complete.
142
143 Copyright
144 ---------
145
146 Copyright 2013-2019 all contributors <meta@public-inbox.org>
147 License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>