Add rewrite rules for websockets
This commit is contained in:
parent
45206f4413
commit
48a4119420
1 changed files with 7 additions and 0 deletions
|
@ -33,5 +33,12 @@
|
||||||
RequestHeader set "X-Forwarded-Proto" expr=%{REQUEST_SCHEME}
|
RequestHeader set "X-Forwarded-Proto" expr=%{REQUEST_SCHEME}
|
||||||
RequestHeader set "X-Forwarded-SSL" expr=%{HTTPS}
|
RequestHeader set "X-Forwarded-SSL" expr=%{HTTPS}
|
||||||
|
|
||||||
|
<ifmodule mod_rewrite.c>
|
||||||
|
# see documentation of wstunnel: This allwos generic websocket passthrough
|
||||||
|
RewriteEngine On
|
||||||
|
RewriteCond %{HTTP:Upgrade} websocket [NC]
|
||||||
|
RewriteCond %{HTTP:Connection} upgrade [NC]
|
||||||
|
RewriteRule ^/?(.*) "ws://{{ backend_host | default("localhost") }}:{{ proxy_port }}/$1" [P,L]
|
||||||
|
</ifmodule>
|
||||||
</VirtualHost>
|
</VirtualHost>
|
||||||
</IfFile>
|
</IfFile>
|
||||||
|
|
Loading…
Reference in a new issue