sologgfun
V2EX  ›  问与答

问一个 nginx 和 websocket 的问题?

  •  
  •   sologgfun · Jul 4, 2019 · 2191 views
    This topic created in 2527 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
        1
    freehere  
       Jul 4, 2019
    wss 443
    SpringBlossom
        2
    SpringBlossom  
       Jul 4, 2019
    wss 直接监听 443 即可
    sologgfun
        3
    sologgfun  
    OP
       Jul 5, 2019
    @freehere
    @Woood 今天试一试 谢谢~
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   5822 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 40ms · UTC 02:08 · PVG 10:08 · LAX 19:08 · JFK 22:08
    ♥ Do have faith in what you're doing.