I'm trying to run a node js with socket io project and it's working only as polling transport and i can't use the WebSocket method I don't know what cause this issue i have tried to update the config file and added (mod_proxy_wstunnel) but it didn't work also the error i get in the console
and this is the code of my config file
<VirtualHost *:80>
ServerAdmin admin@socket
DocumentRoot "/www/wwwroot/socket"
ServerName 80.socket
ServerAlias location.hwilo.com
#errorDocument 404 /404.html
ErrorLog "/www/wwwlogs/socket-error_log"
CustomLog "/www/wwwlogs/socket-access_log" combined
#HTTP_TO_HTTPS_START
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{SERVER_PORT} !^443$
RewriteRule (.*) https://%{SERVER_NAME}$1 [L,R=301]
</IfModule>
#HTTP_TO_HTTPS_END
#DENY FILES
<Files ~ (\.user.ini|\.htaccess|\.git|\.svn|\.project|LICENSE|README.md|package.json|package-lock.json|\.env)$>
Order allow,deny
Deny from all
</Files>
#SSL
ProxyPass /.well-known/ !
# HTTP reverse proxy related settings begin >>>
<IfModule mod_proxy.c>
ProxyRequests Off
SSLProxyEngine on
ProxyPass / http://127.0.0.1:3000/
ProxyPassReverse / http://127.0.0.1:3000/
ProxyTimeout 20000
</IfModule>
<IfModule mod_proxy_wstunnel.c>
ProxyRequests off
SSLProxyEngine on
ProxyPass /socket.io ws://127.0.0.1:3000/socket.io
ProxyPassReverse /socket.io ws://127.0.0.1:3000/socket.io
SetEnv proxy-sendcl 0
ProxyTimeout 50000
</IfModule>
# End of HTTP reverse proxy related settings <<<
</VirtualHost>
<VirtualHost *:443>
ServerAdmin admin@socket
DocumentRoot "/www/wwwroot/socket"
ServerName location.hwilo.com
ServerAlias location.hwilo.com
#errorDocument 404 /404.html
ErrorLog "/www/wwwlogs/socket-error_log"
CustomLog "/www/wwwlogs/socket-access_log" combined
#SSL
SSLEngine On
SSLCertificateFile /www/server/panel/vhost/cert/socket/fullchain.pem
SSLCertificateKeyFile /www/server/panel/vhost/cert/socket/privkey.pem
SSLCipherSuite EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+AES128:RSA+AES128:EECDH+AES256:RSA+AES256:EECDH+3DES:RSA+3DES:!MD5
SSLProtocol All -SSLv2 -SSLv3 -TLSv1
SSLHonorCipherOrder On
#DENY FILES
<Files ~ (\.user.ini|\.htaccess|\.git|\.svn|\.project|LICENSE|README.md|package.json|package-lock.json|\.env)$>
Order allow,deny
Deny from all
</Files>
#SSL
ProxyPass /.well-known/ !
# HTTP reverse proxy related settings begin >>>
<IfModule mod_proxy.c>
ProxyRequests Off
SSLProxyEngine on
ProxyPass / http://127.0.0.1:3000/
ProxyPassReverse / http://127.0.0.1:3000/
</IfModule>
<IfModule mod_proxy_wstunnel.c>
ProxyRequests off
SSLProxyEngine on
ProxyPass /socket.io ws://127.0.0.1:3000/socket.io
ProxyPassReverse /socket.io ws://127.0.0.1:3000/socket.io
SetEnv proxy-sendcl 0
ProxyTimeout 50000
</IfModule>
# End of HTTP reverse proxy related settings <<<
</VirtualHost>