mirror of
https://github.com/OpenEPaperLink/OpenEPaperLink.git
synced 2026-03-21 00:04:28 +01:00
[PR #191] [MERGED] Make WebSocket connection protocol dependent #2107
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/OpenEPaperLink/OpenEPaperLink/pull/191
Author: @pablogonzalezalba
Created: 1/4/2024
Status: ✅ Merged
Merged: 1/4/2024
Merged by: @nlimper
Base:
master← Head:websocket-protocol-dependent📝 Commits (2)
51c4294Support secure WebSockets when loading via httpsb42bb92Update main.js.gz from main.js📊 Changes
2 files changed (+2 additions, -1 deletions)
View changed files
📝
ESP32_AP-Flasher/data/www/main.js.gz(+0 -0)📝
ESP32_AP-Flasher/wwwroot/main.js(+2 -1)📄 Description
Currently, the connection to WebSockets is hardcoded to the protocol
ws://.If the server is put behind a proxy server (like Nginx) to support
https, the connection to websockets will fail (at least in Firefox) due to insecure protocol.This change checks the current protocol and connects to
wssif loaded viahttps, which makes it work when loaded via proxy.I updated the file
main.js.gzby just compressingmain.js. Is that the correct way?Please let me know if I'm missing anything.
Thanks for the great project, I use it a lot!
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.