37 lines
845 B
Nix
37 lines
845 B
Nix
{ config, ... }:
|
|
{
|
|
services = {
|
|
samba = {
|
|
enable = true;
|
|
securityType = "user";
|
|
openFirewall = true;
|
|
extraConfig = ''
|
|
workgroup = WORKGROUP
|
|
server string = JimSMB
|
|
security = user
|
|
hosts allow = ${config.ips.localSpan}. 127.0.0.1 localhost
|
|
hosts deny = 0.0.0.0/0
|
|
guest account = nobody
|
|
map to guest = bad user
|
|
'';
|
|
shares = {
|
|
roms = {
|
|
comment = "Samba share with my ROMs";
|
|
path = "/export/JimboNFS/Downloads/GameFiles/ROMS";
|
|
browseable = "yes";
|
|
"read only" = "no";
|
|
"guest ok" = "no";
|
|
"create mask" = "0644";
|
|
"directory mask" = "0755";
|
|
};
|
|
};
|
|
};
|
|
|
|
# Advertise to Windows
|
|
samba-wsdd = {
|
|
enable = true;
|
|
openFirewall = true;
|
|
};
|
|
};
|
|
}
|