-
Notifications
You must be signed in to change notification settings - Fork 18
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
Advertisements published on first interface only? #3
Comments
Right, I wondered if this might be an issue. It currently binds the socket on Do you need the advertisements on all the other interfaces or just one, like, wlan0? There's a new method (setMulticastInterface) that was added to node in 8.4 that can set the interface to use for outgoing packets. If all your systems can communicate through one of the interfaces that's the easier answer. (I'm actually pretty excited about that one, they didn't have it when I was trying to figure out how to deal with this before.) Otherwise we'll have to create multiple sockets, one for each interface you need to use. Either way I think I should add an option to specify interfaces somehow. |
Oh fine - did not notice the multicastInterface call; that could indeed work out as we've set up a bridge interface on all nodes sharing data. |
Ok great, I'll add an option to use that const ad = new dnssd.Advertisement(dnssd.tcp('thing'), 8000, { interface: 'wlan0' });
// or
const browser = new dnssd.Browser(dnssd.tcp('thing'), { interface: '1.2.3.4' }); I'll let you know when I get that updated! |
Alrighty, I've added that option & published it to npm. Give it a shot and let me know if that works with your network config |
Hi, I'm running into this issue from the other direction. We've got an app browsing for a service that is advertised by a device connected to local wifi.
Is it feasible to pass multiple interfaces to the browser and have it coalesce the results? Ideally, we would be able to discover all available services, regardless of network. |
This is an issue for me. I need the advertisement on all the interfaces with the correct ip address. mdns does this correctly, |
@sbender9 @haakonnessjoen I worked around my issue by finding all of the active network interfaces, creating one browser instance for each interface, and coalescing results from all browsers. That works fine 👍 Also see related fix in #16 |
Hi,
we have an embedded system with a number of interfaces - eth0, wlan0, bat0 - to name a few.
The following code runs
but the services show up only on the first interface that has been detected (eth0 in our case, where we don't want it ... ) -- not even at localhost.
How can we make sure it is accessible from the other network participants?
Simon
The text was updated successfully, but these errors were encountered: