FeministWiki:Server setup: Difference between revisions
Technician (talk | contribs) |
Technician (talk | contribs) No edit summary |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 146: | Line 146: | ||
mariadb-server \ | mariadb-server \ | ||
nginx-extras \ | nginx-extras \ | ||
postfix \ | postfix \ | ||
postfix-ldap \ | postfix-ldap \ | ||
rspamd \ | |||
slapd | slapd | ||
| Line 156: | Line 156: | ||
apt-get install ejabberd/$(lsb_release -sc)-backports # e.g. ejabberd/bookworm-backports | apt-get install ejabberd/$(lsb_release -sc)-backports # e.g. ejabberd/bookworm-backports | ||
=== Install PHP and modules === | === Install PHP and modules === | ||
| Line 167: | Line 161: | ||
This should really be part of the last section, but due to the sheer number of PHP modules we want to install, it's in its own section: | This should really be part of the last section, but due to the sheer number of PHP modules we want to install, it's in its own section: | ||
php_version=8. | php_version=8.4 # or whatever version we're on | ||
apt-get install php${php_version} \ | apt-get install php${php_version} \ | ||
| Line 188: | Line 182: | ||
php${php_version}-zip | php${php_version}-zip | ||
We also want {{C|php-luasandbox}}, which may not have a PHP version attached to the package name, in which case you'll have to make sure it supports the PHP version currently in use. If not, you can use the standalone Lua binary instead by setting {{C|$wgScribuntoDefaultEngine = 'luastandalone';}} in MediaWiki's {{C|LocalSettings.php}} configuration file. | We also want {{C|php-luasandbox}}, which may not have a PHP version attached to the package name, in which case you'll have to make sure it supports the PHP version currently in use. If not, you can use the standalone Lua binary instead by setting {{C|$wgScribuntoDefaultEngine {{=}} 'luastandalone';}} in MediaWiki's {{C|LocalSettings.php}} configuration file. | ||
# See if this works first: | # See if this works first: | ||
| Line 198: | Line 192: | ||
dpkg -L php-luasandbox | dpkg -L php-luasandbox | ||
=== Copy over certificates === | === Copy over certificates and DKIM key === | ||
Copy over the certs from the old server: | Copy over the certs from the old server: | ||
# Run on old server | # Run on old server | ||
rsync -avz /etc/feministwiki/certs feministwiki.dev:/etc/feministwiki | rsync -avz /etc/feministwiki/certs feministwiki.dev:/etc/feministwiki | ||
The {{C|/etc/feministwiki/certs}} directory and its contents should be owned by the group {{C|ssl-cert}}. Make sure this is the case on the new server after running the command above, since the group ID might be different on the new server. If the group doesn't exist at all, just create it. | The {{C|/etc/feministwiki/certs}} directory and its contents should be owned by the group {{C|ssl-cert}}. Make sure this is the case on the new server after running the command above, since the group ID might be different on the new server. If the group doesn't exist at all, just create it. | ||
| Line 219: | Line 213: | ||
# Run on old server | # Run on old server | ||
rsync -avz /etc/letsencrypt/{archive,live} feministwiki.dev:/etc/letsencrypt | rsync -avz /etc/letsencrypt/{archive,live} feministwiki.dev:/etc/letsencrypt | ||
Finally, copy over the DKIM signing key: | |||
rsync -avz /etc/feministwiki/dkim.key feministwiki.dev:/etc/feministwiki | |||
This file must be owned by the {{C|_rspamd}} user and not readable by anyone else. | |||
=== Put config files in place === | === Put config files in place === | ||
| Line 543: | Line 543: | ||
systemctl stop inspircd | systemctl stop inspircd | ||
systemctl stop nginx | systemctl stop nginx | ||
systemctl stop postfix | systemctl stop postfix | ||
systemctl stop rspamd | |||
systemctl stop slapd | systemctl stop slapd | ||
| Line 568: | Line 568: | ||
systemctl stop inspircd | systemctl stop inspircd | ||
systemctl stop nginx | systemctl stop nginx | ||
systemctl stop postfix | systemctl stop postfix | ||
systemctl stop rspamd | |||
systemctl stop slapd | systemctl stop slapd | ||