Proxy socket.io and nginx on the same port, over SSL

· Graham King · Dec. 22, 2011, 10:32 p.m.
Summary
My current project has a realtime part, using socket.io on nodejs, and a web part using django on nginx / gunicorn. Here’s a setup to put them both on the same port, and make them both go over SSL. I’m assuming you’re on Ubuntu. Disclaimer: I got this working last night, so no promises. You’ll certainly want to tweak haproxy’s config for performance. I also only tested it with socket.io’s web socket transport. Overview stunnel decrypts the ssl, so everything after that doesn’t know about it. ...
AUTHOR