Repository navigation
Replies: 1 comment
|
Hello! Looks like you use mdns discovery, which is indeed just for local networks. For internet I'd suggest to use PubsubPeerDiscovery for now. It will require running a "bootstrap" server, just a permanently running peer, which address will be used by other peers to connect to the network and start discovery. We will soon merge Kad DHT discovery protocol, which will be even better option that will be more efficient in case of many peers. Another issue that you may face is that your app may run on a machine behind NAT, so your IP address will not be available for connection from internet (works in case of servers which have public IPs). To solve this issue you either need to setup port forwarding or wait for relay(soon) + hole punching (I hope in 2 months) |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
I've written a simple chat that uses libp2p but it doesn`t work when both peers are not in the same network. Do I have to configure the peer discovery somehow or specify a relay or stun server?
here is my source: https://github.com/furesoft/libp2p-test/
thanks in advance
All reactions