From 7e58b8123e729b301223a99e277d539834f7f0e9 Mon Sep 17 00:00:00 2001 From: David Schoonover Date: Fri, 8 Jun 2012 15:39:13 -0700 Subject: [PATCH] Disable buffering for nginx. --- lib/server/proxy.co | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/lib/server/proxy.co b/lib/server/proxy.co index 15349a5..8dafdf6 100644 --- a/lib/server/proxy.co +++ b/lib/server/proxy.co @@ -26,6 +26,9 @@ ProxyMiddleware = (options={}) -> unless matchesList whitelist, target.hostname return res.send {error:'Domain is not whitelisted'}, 403 + # Set the no-buffering flag for nginx + res.header 'X-Accel-Buffering', 'no' + console.log "[Proxy] #targetUrl" request.get targetUrl .pipe res -- 1.7.0.4