title: nginx websocket connections timeouts after 30 seconds
body: <p>I have a node.js application with socket.io running on an nginx server. The problem is the websocket connection gets timeouted by the nginx, 30 seconds after the connection, even though the connection doesn't remain idle for the whole time. This is my nginx.conf file;</p>
  
  <pre><code>user nginx;
  worker_processes auto;
  error_log /var/log/nginx/error.log;
  pid /run/nginx.pid;
  
  include /usr/share/nginx/modules/*.conf;
  
  events {
      worker_connections 1024;
  }
  
  
  stream {
      upstream cluster {
          least_conn;
          server xx.xxx.xxx.xx:2157;
      }
  
      server {
          listen 7000;
          preread_timeout 86400s;
          proxy_timeout 86400s;
          proxy_pass cluster;
      }
  }
  </code></pre>
  
  <p>The nginx version is: 1.12.2</p>