I was seeking to get autofs
-like behaviour for smb-based servers/shares by leveraging gio list smb://
and gio mount ...
.
My starting point is nemo
working with Network browsing.
I can also use e.g. gio mount smb://192.168.1.81/scan/
to do a mount like in nemo
, which results in
$ ls -1 /run/user/1000/gvfs/
'smb-share:server=192.168.1.81,share=scan'
BUT:
- I get
$ gio list smb:// gio: smb:///: The specified location is not mounted
nemo
does not show NixOS smb servers, only NAS and VMs. It appears to be the same list I get as withavahi-browse -rt -a | grep smb
. I understand this to be related to (not having)wsdd
, but simply enabling thesamba-wsdd
service on some of the NixOS servers doesn’t make a difference innemo
, and no matter what I do, I keep getting the result under (1)- I’ve tried manually running
wsdd -D
on a client, and then/nix/store/7z2zldyzgy7973nr9ipk7ksv85savqh5-gvfs-1.56.1/libexec/gvfsd-network
, which gives meCouldn't create directory monitor on wsdd:///. Error: Automount failed: Failed to spawn the underlying wsdd daemon.
(The gvfs store path was taken from$GIO_EXTRA_MODULES
) - I tried enabling
avahi
on on server, but I get a warning that something else is running on5353
, and the server still doesn’t show up on a client withavahi-browse
ornemo
- On server and client I now have:
services = { gvfs = { enable = true; # FIXME: does this help wsdd and cli gio stuff??? package = pkgs.gvfs.override {gnomeSupport = true;}; # unnecessary with the below? }; gnome.glib-networking.enable = true; # FIXME: does this help wsdd and cli gio stuff??? avahi = { enable = true; allowInterfaces = [config.networking.interfaces.br0.name]; publish.enable = true; }; };
and I could go on, but pretty much nothing makes a difference. What’s going on?