如标题所述,我无法从通过 HTTPS 提供服务的网站连接到 deepstream 服务器。我可以通过本地服务器连接它。
最初我收到以下错误:
deepstream.min.js:3 Mixed Content: The page at 'https://example.com' was loaded over HTTPS, but attempted to connect to the insecure WebSocket endpoint 'ws://<deepstream-domain>:6020/deepstream'. This request has been blocked; this endpoint must be available over WSS.
收到此错误后,我将连接字符串更改为wss://<deepstream-domain>
.
但这会引发以下错误:
WebSocket connection to 'wss://<deepstream-domain>:6020/deepstream' failed: Error in connection establishment: net::ERR_CONNECTION_CLOSED
{"isTrusted":true}
知道如何解决这个问题吗?我是否也必须在 deepstream 服务器中设置 SSL 证书?