I am trying to setup a CouchDB deployment that needs to have the ability to return gzip'd responses (12mb uncompressed vs 400kb compressed responses). I also need to have SSL support and CORS.
I have used Apache as a reverse proxy before, but I have found that it is unreliable for large replications over poor connections. My preference is to directly serve CouchDB, without any proxy, and we are currently serving SSL from within CouchDB.
I have had success setting up this proxy: http://broken-by.me/tag/accept-encoding-gzip/ which uses node and the connect module (plus cors and compression). It's super simple and works fine. Then, anytime I need a gzip'd response I just send the request to a different port. But this means I lose SSL for these requests. Should I figure out how to add SSL to node? Or do people recommend ngingx as a proxy in front of everything, and then use nginx to do gzip, cors and ssl? What is best practice for production CouchDB deployment?