2024-11-19 10:31:29 +01:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
config,
|
|
|
|
...
|
|
|
|
}:
|
2024-03-21 15:00:36 +01:00
|
|
|
{
|
|
|
|
services.netatalk = {
|
|
|
|
enable = true;
|
|
|
|
settings = {
|
|
|
|
Homes = {
|
|
|
|
"basedir regex" = "/home";
|
|
|
|
path = "Public";
|
|
|
|
};
|
|
|
|
time-machine = {
|
|
|
|
path = "/mnt/backup/tm_share";
|
|
|
|
"valid users" = "harald";
|
|
|
|
"time machine" = true;
|
|
|
|
};
|
|
|
|
Qmultimedia = {
|
|
|
|
path = "/mnt/raid/Qmultimedia";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
services.avahi = {
|
|
|
|
enable = true;
|
2024-10-16 14:43:36 +02:00
|
|
|
nssmdns4 = true;
|
|
|
|
nssmdns6 = true;
|
|
|
|
ipv6 = true;
|
|
|
|
ipv4 = true;
|
2024-03-21 15:00:36 +01:00
|
|
|
publish = {
|
|
|
|
enable = true;
|
|
|
|
userServices = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
services.samba = {
|
|
|
|
enable = true;
|
|
|
|
openFirewall = true;
|
2024-11-28 10:01:46 +01:00
|
|
|
settings = {
|
|
|
|
global = {
|
|
|
|
security = "user";
|
|
|
|
"read raw" = "Yes";
|
|
|
|
"write raw" = "Yes";
|
|
|
|
"socket options" = "TCP_NODELAY IPTOS_LOWDELAY SO_RCVBUF=131072 SO_SNDBUF=131072";
|
|
|
|
"min receivefile size" = 16384;
|
|
|
|
"use sendfile" = true;
|
|
|
|
"aio read size" = 16384;
|
|
|
|
"aio write size" = 16384;
|
|
|
|
"workgroup" = "WORKGROUP";
|
|
|
|
"server string" = "sgx";
|
|
|
|
"netbios name" = "sgx";
|
|
|
|
#"max protocol" = "smb2";
|
|
|
|
"hosts allow" = "192.168.178. 127.0.0.1 localhost 2003::/16 ::1";
|
|
|
|
"hosts deny" = "ALL";
|
|
|
|
"guest account" = "nobody";
|
|
|
|
"map to guest" = "bad user";
|
|
|
|
};
|
2024-03-21 15:00:36 +01:00
|
|
|
Qmultimedia = {
|
|
|
|
path = "/mnt/raid/Qmultimedia";
|
|
|
|
browseable = "yes";
|
|
|
|
"read only" = "no";
|
|
|
|
"guest ok" = "no";
|
|
|
|
"create mask" = "0644";
|
|
|
|
"directory mask" = "0755";
|
|
|
|
"force user" = "harald";
|
|
|
|
"force group" = "users";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
2024-08-03 15:53:10 +02:00
|
|
|
|
|
|
|
services = {
|
|
|
|
syncthing = {
|
|
|
|
enable = true;
|
|
|
|
user = "harald";
|
|
|
|
dataDir = "/mnt/raid/Qmultimedia/syncthing"; # Default folder for new synced folders
|
|
|
|
configDir = "/mnt/raid/Qmultimedia/syncthing/.config/syncthing"; # Folder for Syncthing's settings and keys
|
2024-08-03 15:58:30 +02:00
|
|
|
guiAddress = "0.0.0.0:8384";
|
2024-08-03 15:53:10 +02:00
|
|
|
};
|
|
|
|
};
|
2024-03-21 15:00:36 +01:00
|
|
|
}
|