@Kowlin Thanks for your help with this!
Apache 2.2.15 with websocket not working...already backported mod_proxy_wstunnel
I asked awhile ago about websocket. I figured out exactly what my issue is with websockets. It is the fact that my server is CentOS6 and can only run Apache 2.2.15.
I've followed steps in https://docs.nodebb.org/en/latest/configuring/proxies/apache2.2.html to backport mod_proxy_wstunnel from apache 2.4 to apache 2.2, but when I run my site I still get
WebSocket connection to 'ws://mongo.dbc.hoathenguyen.com/socket.io/?EIO=3&transport=websocket&sid=bgi9Edghqhl_Gjl-AABk' failed: Error during WebSocket handshake: Unexpected response code: 400
This is what my Apache conf file looks like
LoadModule proxy_wstunnel_module modules/mod_proxy_wstunnel.so <VirtualHost 188.8.131.52:80> ServerAdmin "email@example.com" ServerName "mongo.dbc.hoathenguyen.com:80" ServerAlias "www.mongo.dbc.hoathenguyen.com" ServerAlias "ipv4.mongo.dbc.hoathenguyen.com" ProxyRequests off <Proxy *> order deny,allow allow from all </Proxy> ProxyPass /socket.io/1/websocket ws://127.0.0.1:4568/socket.io/1/websocket ProxyPassReverse /socket.io/1/websocket ws://127.0.0.1:4568/socket.io/1/websocket ProxyPass /socket.io/ http://127.0.0.1:4568/socket.io/ ProxyPassReverse /socket.io/ http://127.0.0.1:4568/socket.io/ ProxyPass / http://127.0.0.1:4568/ ProxyPassReverse / http://127.0.0.1:4568/ </VirtualHost>
Can someone tell me what I am doing wrong?
Also note mongo.dbc.hoathenguyen.com is a forum I'm testing with....the real forum is down because I noticed all the failed websocket calls from all the users were killing my Apache server and making my other sites useless. =(
Well fixed the issue, just updated the ProxyPass
ProxyPass /socket.io/ ws://localhost:4568/socket.io/ ProxyPassReverse /socket.io/ ws://localhost:4568/socket.io/
Don't get why in the documentation it uses socket.io/1/websocket....would explain why I was not able to connect to the websocket.