nginx and proxying WebSockets nginx and proxying WebSockets nginx nginx

nginx and proxying WebSockets


Problem 1: As for the connection dying once a minute, I realized that it's nginx timeout variable. I can either make our app to ping once in a while or increase the timeout. I'm not sure if I should set it as 0, I decided to just ping once a minute and set the timeout to 90 seconds. (keepalive_timeout)

Problem 2: Connectivity issues arose when I used CloudFlare CDN. Disabling CloudFlare acceleration solved the problem.

Alternatively I could create a subdomain and set it as "unaccelerated" and use that for WS.