From 4204d84bde2d9d4ff91c8963e4eaf001cb154ff4 Mon Sep 17 00:00:00 2001 From: Scott Lamb Date: Fri, 13 Aug 2021 15:28:31 -0700 Subject: [PATCH] disable proxy buffering in nginx Buffering to local disk is unnecessary and wasteful. Moonfire connections are cheap. --- guide/secure.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/guide/secure.md b/guide/secure.md index 0520c6a..d1933ab 100644 --- a/guide/secure.md +++ b/guide/secure.md @@ -211,7 +211,7 @@ desired DNS name. Now finalize its configuration: The author's system does this via the following `/etc/nginx/sites-available/nvr.home.slamb.org` file: -``` +```nginx upstream moonfire { server 127.0.0.1:8080; } @@ -233,9 +233,9 @@ server { } proxy_http_version 1.1; + proxy_buffering off; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection $connection_upgrade; - proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Real-IP $remote_addr; proxy_set_header Host $http_host;