How to use Apache to run as a web server
https://www.apachehaus.com/cgi-bin/download.plx
Download Apache2.4(x86 / x64) from this site. Link above
Unzip apache to a desired location
Open httpd.conf
Eg. C:\httpd-2.4.33-o102o-x64-vc14-r2\Apache24\conf\httpd.confSet “ServerRoot” as the parent directory apache directory
Eg. ServerRoot "C:\httpd-2.4.33-o102o-x64-vc14-r2\Apache24"Make sure you have these lines modules loaded in httpd.conf, uncomment if commented
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_http2_module modules/mod_proxy_http2.so
LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule ssl_module modules/mod_ssl.soAdd the following config in your httpd.conf
<VirtualHost *:80>
ServerName localhost
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/editor [NC,OR]
RewriteCond %{QUERY_STRING} transport=websocket [NC]
RewriteCond %{HTTP:UPGRADE} ^WebSocket$ [NC,OR]
RewriteCond %{HTTP:CONNECTION} ^Upgrade$ [NC]
RewriteRule /(.*) ws://localhost:8081%{REQUEST_URI} [P,L]
ProxyRequests Off
ProxyPreserveHost On
...