Hey... saw your comment here http://news.ycombinator.com/item?id=5172775 about the work you did on unrolling arrays in mongo_fdw. Any chance you can email me about it (that thread is closed). username @ gmail.com
HAProxy has had Websocket support for a while now. But other than that, you can run run on the same domain without a proxy by just using a different port.
1. Run nginx with something like HAProxy/Varnish infront
2. Run nginx alone with the app server on port 80/443 and the websocket server running on a special port. The app was then proxyed using the built in http_proxy, while the websocket was handled by tcp_proxy.