Revert "Use [] instead of nil"
[akkoma] / installation / pleroma-apache.conf
1 <VirtualHost *:80>
2 #Example configuration for when Apache httpd and Pleroma are on the same host.
3 #Needed modules: proxy proxy_http proxy_wstunnel rewrite
4 #This assumes a Debian style Apache config. Put this in /etc/apache2/sites-available
5 #Doesn't include SSL, just run certbot and let it take care of that.
6
7
8 #Change this:
9 ServerName pleroma.example.com
10
11 RewriteEngine On
12 RewriteCond %{HTTP:Connection} Upgrade [NC]
13 RewriteCond %{HTTP:Upgrade} websocket [NC]
14 RewriteRule /(.*) ws://localhost:4000/$1 [P,L]
15
16 ProxyRequests off
17 ProxyPass / http://localhost:4000/
18 ProxyPassReverse / http://localhost:4000/
19
20 #Change this too:
21 RequestHeader set Host "pleroma.example.com"
22 ProxyPreserveHost On
23
24 ErrorLog ${APACHE_LOG_DIR}/error.log
25 CustomLog ${APACHE_LOG_DIR}/access.log combined
26 </VirtualHost>