From 6cca689ef7c00a03e24149237c26722c0f61b6e5 Mon Sep 17 00:00:00 2001 From: John Livingston Date: Thu, 6 May 2021 13:59:45 +0200 Subject: [PATCH] Trying to fix for production. --- CHANGELOG.md | 6 ++++++ server/lib/routers/webchat.ts | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d89ad48d..73022474 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## v2.1.1 + +### Fixes + +* Fix bad proxy settings when not working on localhost + ## v2.1.0 ### Important Notes diff --git a/server/lib/routers/webchat.ts b/server/lib/routers/webchat.ts index e224dee8..d252811a 100644 --- a/server/lib/routers/webchat.ts +++ b/server/lib/routers/webchat.ts @@ -115,7 +115,7 @@ function changeHttpBindRoute ({ peertubeHelpers }: RegisterServerOptions, port: proxyReqPathResolver: async (_req: Request): Promise => { return '/http-bind' // should not be able to access anything else }, - // preserveHostHdr: false, + preserveHostHdr: true, parseReqBody: true // Note that setting this to false overrides reqAsBuffer and reqBodyEncoding below. // FIXME: should we remove cookies? }