Hi Guys,
I’m trying to create 3 different samba shares with different user/password and connect to them from MacOS.
Share:Media → user:Media
Share:InAndOut → user: PUBLIC
Share:Documents → user:john
so now my problem is that in MacOS if I connect to “nixSamba” as john, I actually see also the Media content, instead I will like to have and different user password for the Media share
is that because I need to create different mnt?
services.samba = {
enable = true;
securityType = "user";
extraConfig = ''
workgroup = WORKGROUP
server string = nixsamba
netbios name = nixsamba
security = user
#use sendfile = yes
#max protocol = smb2
# note: localhost is the ipv6 localhost ::1
hosts allow = 192.168.10. 192.168.20. 127.0.0.1 localhost
hosts deny = 0.0.0.0/0
guest account = nobody
map to guest = bad user
'';
shares = {
Media = {
path = "/mnt/usb-wd-external/Media";
browseable = "yes";
"read only" = "no";
"guest ok" = "no";
"create mask" = "0644";
"directory mask" = "0755";
"force user" = "media"; # <---------
"force group" = "users";
};
# public
InAndOut = {
path = "/mnt/usb-wd-external/InAndOut";
browseable = "yes";
"read only" = "no";
"guest ok" = "yes"; # <---------
"create mask" = "0644";
"directory mask" = "0755";
"force user" = "john";
"force group" = "users";
};
Documents = {
path = "/mnt/usb-wd-external/Documents";
browseable = "yes";
"read only" = "no";
"guest ok" = "no";
"create mask" = "0644";
"directory mask" = "0755";
"force user" = "john"; # <---------
"force group" = "users";
};