Question

Need to configure socket.io over ssl using nginx

Hi, We have hosted www.breety.com on your server and it is working fine. But right now we are trying to use nodejs (socket.io) over ssl on nginx server on port 7024.

We have tested on local environment using nginx server and socket,and its working fine.But on live environment we are facing errors as given below:

  1. GET https://www.breety.com:7024/socket.io/?EIO=3&transport=polling&t=LkVPrSN net::ERR_TIMED_OUT

  2. GET https://www.breety.com:7024/socket.io/?EIO=3&transport=polling&t=LkVPrSN net::ERR_CONNECTION_REFUSED

please guide us how to configure socket.io over ssl using nginx.?

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi there - If you are trying to keep open a persistent connection have you tried using a product like https://www.pubnub.com/docs/nodejs-javascript/pubnub-javascript-sdk which uses standard SSL port 443 and doesn’t require you to open any additional ports. (full discloser I work for PubNub). Or take a look at this open source package that lets you switch between realtime providers http://rltmjs.com/

Hi @hirengm

This is the community forum (meaning user-to-user support).

Can you post your Nginx configuration of the server blocks? The problem most like is here - or that development environment most likely didn’t have https.