Skip to content
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 connect to peer outside of local network #108

Open
frobinsonj opened this issue Jul 8, 2020 · 0 comments
Open

Unable to connect to peer outside of local network #108

frobinsonj opened this issue Jul 8, 2020 · 0 comments

Comments

@frobinsonj
Copy link

frobinsonj commented Jul 8, 2020

Hi, I am having issues connecting peers to other peers outside of their local network. I assume this is something to do with the STUN servers. I am quite new to this WebRTC stuff and I would appreciate any help in getting this working. I am not receiving the stream:added event.

Any help would be appreciated, thanks in advance.

Below is the setup (simplified)

quickconnect('<switchboard server>', {
  room: '<room>',
  expectedLocalStreams: 1,
  debug: true,
  iceServers: [{
    urls: [
    'stun:stun1.l.google.com:19302',
    'stun:stun2.l.google.com:19302',
    'stun:stun3.l.google.com:19302',
    'stun:stun4.l.google.com:19302'
    ]
  }]
})
.createDataChannel('textChat')
.addStream(stream)

This is the debug output:

rtc-quickconnect: [ckcdggkx700003b67bdts8ylc] call has been created for ckcdgihwd00003e68nljykr26 (not yet started)
rtc-quickconnect: channel textChat discovered for peer: ckcdgihwd00003e68nljykr26
rtc-quickconnect: channel not ready, current state = connecting
rtc-quickconnect: coupling ckcdggkx700003b67bdts8ylc to ckcdgihwd00003e68nljykr26
rtc/couple: [ckcdggkx700003b67bdts8ylc] ready for coupling to ckcdgihwd00003e68nljykr26
rtc/couple: [ckcdggkx700003b67bdts8ylc] ckcdgihwd00003e68nljykr26 not yet ready for offer
rtc/couple: [ckcdggkx700003b67bdts8ylc] ckcdgihwd00003e68nljykr26 is ready for coupling
rtc/couple: [ckcdggkx700003b67bdts8ylc] ckcdgihwd00003e68nljykr26 has requested a negotiation
rtc/couple: [ckcdggkx700003b67bdts8ylc] ckcdgihwd00003e68nljykr26 has requested the ability to create the offer
rtc/couple: [ckcdggkx700003b67bdts8ylc] Creating new offer for ckcdgihwd00003e68nljykr26
rtc-quickconnect: [ckcdggkx700003b67bdts8ylc] peer ckcdgihwd00003e68nljykr26 detected track
rtc/couple: [ckcdggkx700003b67bdts8ylc] signaling state have-remote-offer to ckcdgihwd00003e68nljykr26
rtc/couple: renegotiation is required, but deferring until existing connection is established
rtc/couple: [ckcdggkx700003b67bdts8ylc] signaling state stable to ckcdgihwd00003e68nljykr26
rtc/couple: [ckcdggkx700003b67bdts8ylc] coupling completed to ckcdgihwd00003e68nljykr26
rtc/couple: signalling stable and a negotiation is required, so creating one
rtc/couple: [ckcdggkx700003b67bdts8ylc] Creating new offer for ckcdgihwd00003e68nljykr26
rtc/couple: [ckcdggkx700003b67bdts8ylc] Creating new offer for connection to ckcdgihwd00003e68nljykr26
rtc-quickconnect: checking channel state, current state = connecting, connection state new
rtc/couple: reset disconnect timer, state: checking
rtc-quickconnect: checking channel state, current state = connecting, connection state checking
rtc/couple: reset disconnect timer, state: checking
rtc/couple: [ckcdggkx700003b67bdts8ylc] signaling state have-local-offer to ckcdgihwd00003e68nljykr26
rtc/couple: reset disconnect timer, state: checking
rtc/couple: [ckcdggkx700003b67bdts8ylc] signaling state stable to ckcdgihwd00003e68nljykr26
rtc/couple: [ckcdggkx700003b67bdts8ylc] coupling completed to ckcdgihwd00003e68nljykr26
rtc/couple: coupling complete, can now trigger any pending renegotiations
rtc-quickconnect: checking channel state, current state = connecting, connection state checking
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant