From 6c3a5793b4b88466087e17b9365320d19f8b885b Mon Sep 17 00:00:00 2001 From: paweldomas Date: Mon, 27 Jan 2020 14:54:27 -0600 Subject: [PATCH] fix(webpack.config.js): specify Host header in the webpack proxy pass Without changing the 'Host' header, a standalone instance we use for jitsi dev work will generate: config.websocket = 'wss://localhost:8080/xmpp-websocket' This was fine with BOSH, but a Websocket will not connect. With this change it will be(based on the default devServerProxyTarget): config.websocket = 'wss://alpha.jitsi.net/xmpp-websocket' --- webpack.config.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/webpack.config.js b/webpack.config.js index 43d92e408..72407cfe5 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -38,7 +38,10 @@ const config = { '/': { bypass: devServerProxyBypass, secure: false, - target: devServerProxyTarget + target: devServerProxyTarget, + headers: { + 'Host': new URL(devServerProxyTarget).host + } } } },