Add configuration
This commit is contained in:
1 parent
eb62e19766
commit
3b4fe6f60c
16 files changed
+1488
No files matched your search
@@ -0,0 +1,53 @@
|
||||
{
|
||||
fileSystems."/mnt/nfs" = {
|
||||
device = "/nfs";
|
||||
options = ["bind"];
|
||||
fsType = "none";
|
||||
};
|
||||
|
||||
services.nfs.server.enable = true;
|
||||
services.nfs.server.exports = ''
|
||||
/nfs 10.1.1.0/22(rw,fsid=0,no_subtree_check)
|
||||
'';
|
||||
services.nfs.server.lockdPort = 4001;
|
||||
services.nfs.server.mountdPort = 4002;
|
||||
services.nfs.server.statdPort = 4003;
|
||||
|
||||
services.samba = {
|
||||
enable = true;
|
||||
securityType = "user";
|
||||
openFirewall = true;
|
||||
settings = {
|
||||
global = {
|
||||
"workgroup" = "WORKGROUP";
|
||||
"server string" = "singularity-smb";
|
||||
"netbios name" = "singularity-smb";
|
||||
"security" = "user";
|
||||
#"use sendfile" = "yes";
|
||||
#"max protocol" = "smb2";
|
||||
# note: localhost is the ipv6 localhost ::1
|
||||
"hosts allow" = "10.1.1. 127.0.0.1 localhost";
|
||||
"hosts deny" = "0.0.0.0/0";
|
||||
"guest account" = "nobody";
|
||||
"map to guest" = "bad user";
|
||||
};
|
||||
"public" = {
|
||||
"path" = "/games";
|
||||
"browseable" = "yes";
|
||||
"read only" = "no";
|
||||
"guest ok" = "no";
|
||||
"create mask" = "0644";
|
||||
"directory mask" = "0755";
|
||||
"force user" = "kasey";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
services.samba-wsdd = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [111 2049 4000 4001 4002 20048];
|
||||
networking.firewall.allowedUDPPorts = [111 2049 4000 4001 4002 20048];
|
||||
}
|
||||
Reference in new issue
Block a user