Open ismell opened 4 years ago
IMO integrating D-Bus directly in wsdd appears to be show-stopper. There is hardly any way to do so without having hard dependencies on some kind of D-Bus library. This is something I really don't like to have.
My current approach to react on Samba's D-Bus notifications in wsdd would be the following:
Does that sound like a possible solution?
Hi,
sorry for probably out of date comment.
Actually this is better not to subscribe to D-Bus messages that Avahi uses for its client/server communications, but instead, acting as Avahi client (I believe, Avahi client library for Python does exist), browse for the _smb._tcp service announces on DNS-SD that match the local host addresses.
Samba uses the avahi-client/D-Bus to announce to
avahi
that a the server is available. WSDD currently relies on therc
system to ensure samba is started beforewsdd
.wsdd
could subscribe to the same messages thatavahi
listens for and then publish the service. This would allowwsdd
to start beforesmbd
and then whensmbd
is ready, it could announce the share. This would also have the advantage that ifsmbd
dies,wsdd
could remove the service.