mirror of
https://github.com/schlagmichdoch/PairDrop.git
synced 2025-04-20 15:06:15 -04:00
Fix and update apache config (fixes #312)
This commit is contained in:
parent
3e502a76d0
commit
b34b3f7b39
1 changed files with 4 additions and 20 deletions
|
@ -556,10 +556,6 @@ a2enmod proxy
|
||||||
a2enmod proxy_http
|
a2enmod proxy_http
|
||||||
```
|
```
|
||||||
|
|
||||||
```bash
|
|
||||||
a2enmod proxy_wstunnel
|
|
||||||
```
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
Create a new configuration file under `/etc/apache2/sites-available` (on Debian)
|
Create a new configuration file under `/etc/apache2/sites-available` (on Debian)
|
||||||
|
@ -570,18 +566,10 @@ Create a new configuration file under `/etc/apache2/sites-available` (on Debian)
|
||||||
|
|
||||||
```apacheconf
|
```apacheconf
|
||||||
<VirtualHost *:80>
|
<VirtualHost *:80>
|
||||||
ProxyPass / http://127.0.0.1:3000/
|
ProxyPass / http://127.0.0.1:3000/ upgrade=websocket
|
||||||
RewriteEngine on
|
|
||||||
RewriteCond %{HTTP:Upgrade} websocket [NC]
|
|
||||||
RewriteCond %{HTTP:Connection} upgrade [NC]
|
|
||||||
RewriteRule ^/?(.*) "ws://127.0.0.1:3000/$1" [P,L]
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
<VirtualHost *:443>
|
<VirtualHost *:443>
|
||||||
ProxyPass / https://127.0.0.1:3000/
|
ProxyPass / https://127.0.0.1:3000/ upgrade=websocket
|
||||||
RewriteEngine on
|
|
||||||
RewriteCond %{HTTP:Upgrade} websocket [NC]
|
|
||||||
RewriteCond %{HTTP:Connection} upgrade [NC]
|
|
||||||
RewriteRule ^/?(.*) "wws://127.0.0.1:3000/$1" [P,L]
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
@ -592,11 +580,7 @@ Create a new configuration file under `/etc/apache2/sites-available` (on Debian)
|
||||||
Redirect permanent / https://127.0.0.1:3000/
|
Redirect permanent / https://127.0.0.1:3000/
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
<VirtualHost *:443>
|
<VirtualHost *:443>
|
||||||
ProxyPass / https://127.0.0.1:3000/
|
ProxyPass / http://127.0.0.1:3000/ upgrade=websocket
|
||||||
RewriteEngine on
|
|
||||||
RewriteCond %{HTTP:Upgrade} websocket [NC]
|
|
||||||
RewriteCond %{HTTP:Connection} upgrade [NC]
|
|
||||||
RewriteRule ^/?(.*) "wws://127.0.0.1:3000/$1" [P,L]
|
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue