简体   繁体   中英

Unable to make websocket connection from webapp's JS when using Latchet framework deployed on CentOS server

We are developing a webapp on Laravel framework to be deployed on CentOS linux server. For updates pushable from server to the browser, we are using Latchet . We did the development on the Windows machine, and on there our webapp side (HTML/JS on browser) is able to make connections to the websocket server (Latchet), and hence successfully getting the server push notifications. The problem is that, when we do the actual deployment on our staging server on CentOS, the webapp side is not being able to make the websocket connection with the Latchet server.

We have checked all the dependencies, firewall, and network settings. We also telnet to the exposed websocket IP and port, and it connects with no issue. My suspicion is in the some configuration we are missing rite now.

it turn out the issue was only due to port blocking by the local firewall. Thus as soon as I stopped the iptables and ip6tables services, my issue immediately resolved.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM