sologgfun
V2EX  ›  问与答

问一个 nginx 和 websocket 的问题?

  •  
  •   sologgfun · Jul 4, 2019 · 2539 views
    This topic created in 2704 days ago, the information mentioned may be changed or developed.

    1.由于想上 serviceWork 导致页面需要用 https

    2.由于上了 https 需要把 websocket 转成 wss

    3.websocket 的服务器本身有一层 nginx,这一层 nginx 上有配置 443 接口的 https 连接

    [问] 那我建立 wss 连接的时候是不是用 node 直接监听这个 443 接口的就是 https 连接呀

    3 replies  •  2019-07-05 08:10:07 +08:00
    freehere
    freehere
    Jul 4, 2019
    1
    wss 443
    SpringBlossom
    SpringBlossom
    Jul 4, 2019
    2
    wss 直接监听 443 即可
    sologgfun
    sologgfun
    OP
    Jul 5, 2019
    3
    @freehere
    @Woood 今天试一试 谢谢~
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   1844 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 04:52 · PVG 12:52 · LAX 20:52 · JFK 23:52
    ♥ Do have faith in what you're doing.