added NFS server

This commit is contained in:
willifan 2024-10-19 23:26:42 +02:00
parent c51fb4c196
commit 13b2821dd3
2 changed files with 22 additions and 0 deletions

View file

@ -12,6 +12,7 @@
./homeassistant.nix
./invidious.nix
./minecraft.nix
./nfs.nix
./radicale.nix
./syncthing.nix

21
hosts/Anton/nfs.nix Normal file
View file

@ -0,0 +1,21 @@
{ ... }:
{
fileSystems = {
"/export/roms" = {
device = "/mnt/data/willifan";
options = [ "bind" ];
};
};
services.nfs.server = {
enable = true;
exports = ''
/export *(rw,fsid=0,no_subtree_check)
/export/roms *(rw,nohide,insecure,no_subtree_check)
'';
};
networking.firewall.allowedTCPPorts = [ 2049 ];
}