Apache Proxy Problem Help Please
-
Hey Awesome NodeBB peeps,
i have installed the apache proxy and have this error
File does not exist: /var/www/socket.io, referer: http://forum.elysium-gaming.tk/admin/index
**
My virtualhost is this**<VirtualHost *:80>
ServerAdmin [email protected]
ServerName forum.elysium-gaming.tk
ServerAlias forum.elysium-gaming.tkProxyRequests off <Proxy *> Order deny,allow Allow from all </Proxy> ProxyPass /socket.io/1/websocket ws://188.226.185.188:4567/socket.io/1/websocket ProxyPassReverse /socket.io/1/websocket ws://188.226.185.188:4567/socket.io/1/websocket ProxyPass /socket.io/ http://188.226.185.188:4567/socket.io/ ProxyPassReverse /socket.io/ http://188.226.185.188:4567/socket.io/ ProxyPass / http://188.226.185.188:4567/ ProxyPassReverse / http://188.226.185.188:4567/
</VirtualHost>
Any help appreciated
xCausxn
-
@bdharrington7
On the NodeBB wiki they say to use thisProxyRequests off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass /socket.io/1/websocket ws://127.0.0.1:4567/socket.io/1/websocket
ProxyPassReverse /socket.io/1/websocket ws://127.0.0.1:4567/socket.io/1/websocketProxyPass /socket.io/ http://127.0.0.1:4567/socket.io/
ProxyPassReverse /socket.io/ http://127.0.0.1:4567/socket.io/ProxyPass / http://127.0.0.1:4567/
ProxyPassReverse / http://127.0.0.1:4567/ -
@xCausxn I wrote the guide for Apache, but like you, this kinda made me think about switching to nginx and I did. Using php-fpm for handling php requests, and the passthrough works like a charm.
The main thing about apache is that most distros have apache 2.2.x which doesnt include the proper proxy tunnel module for web sockets. You either need 2.4.x, or backport the module to 2.2.x which is in the guide.
Since moving to nginx though, I question why I didnt do it sooner..