-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to get peerjs working on LAN #608
Comments
@fresheneesz open Search for This here: |
Hmm, I got frustrated by this and quit til now. Trying again, it works! I did try disabling |
Seems to work even after explicitly enabling it. Odd, well I have moved apartments and have messed with my network configuration - so maybe that's it? Thanks for the help! |
Is there any way to get around this issue without enabling the flag? 2 years later we obviously have a new version of chrome and they have removed it. Also, in this situation, I don't have access to the group policy editor so that method isn't an option either... If it's impossible that's fine but just checking before I completely restructure everything. Thanks! |
I've been successful in testing peerjs from one localhost browser window to another, but when trying to connect via a different computer on the same LAN (connected to the same wifi network), I'm not able to create a successful webrtc connection.
I'm able to successfully connect to the peer server in both cases, however when trying to connect over the LAN, no offer (or corresponding answer) is given.
My code:
server.js: https://pastebin.com/bmbScpGr
client.html: https://pastebin.com/8NXLAVyg
Run the clients by
The relevant (non-heartbeat) websocket frames (note the listener is named "1" and the connector is named "2") in chronological order:
Listener receive 🡇: {"type":"OPEN"}
Connector receive 🡇: {"type":"OPEN"}
Connector send 🡅:
Connector send 🡅:
Listener receive 🡇:
Listener receive 🡇:
I noticed that in the successful localhost test, the first thing the connector does is make an OFFER, however no OFFER is given at all in the unsuccessful LAN test. This is the offer given in the successful test:
Another thing I noticed is that the candidate sent by the connector is slightly different (and there's only one instead of two) - there's the string
5ca864aa-cd92-4296-b875-6d8ed2303d43.local
instead of an IP address192.168.0.104
:Note that I also tried the reverse (loading the listener on the separate machine and the connector on the same machine as the peerjs server), which also didn't work. The websocket frames were a bit more complex tho.
Does anyone know what might be going on here? I figured a test over a LAN should be just as easy as a local demo, since there's no NAT to traverse.
The text was updated successfully, but these errors were encountered: