Skip to content

Instantly share code, notes, and snippets.

@wescleymatos
Created October 8, 2018 17:16
Show Gist options
  • Save wescleymatos/c66deb3e69f52b7c80c5ef33b2fba01d to your computer and use it in GitHub Desktop.
Save wescleymatos/c66deb3e69f52b7c80c5ef33b2fba01d to your computer and use it in GitHub Desktop.
proxy reverse apache
ServerAdmin webmaster@localhost
ProxyRequests Off
ProxyPreserveHost On
ProxyVia Full
RewriteEngine On
RewriteCond %{REQUEST_URI} ^/socket.io [NC]
RewriteCond %{QUERY_STRING} transport=websocket [NC]
RewriteRule /(.*) ws://127.0.0.1:3000/$1 [P,L]
ProxyPass /chat http://127.0.0.1:3000
ProxyPassReverse /chat http://127.0.0.1:3000
ProxyPass /socket.io http://127.0.0.1:3000/socket.io
ProxyPassReverse /socket.io http://127.0.0.1:3000/socket.io
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment