Personal-use NixOS configuration

Minor tweaks to mkShares function

+14 -3
+10 -2
hosts/index/config/nfs.nix
··· 25 25 26 26 shares = [ 27 27 { 28 - name = "torrents"; 28 + name = "Torrents"; 29 29 30 30 path = "/mnt/data/rtorrent/downloads"; 31 31 ··· 33 33 groupName = mediaGroupName; 34 34 } 35 35 { 36 - name = "soulseek"; 36 + name = "Soulseek"; 37 37 38 38 path = "/mnt/data/soulseek/downloads"; 39 39 40 40 userName = config.services.slskd.user; 41 41 groupName = mediaGroupName; 42 42 } 43 + # { 44 + # name = "Rips"; 45 + 46 + # path = "/mnt/data/rips"; 47 + 48 + # userName = "encode42"; 49 + # groupName = mediaGroupName; 50 + # } 43 51 { 44 52 path = "/mnt/data/media/Music"; 45 53
+4 -1
lib/mkShares.nix
··· 23 23 24 24 user = config.users.users.${target.userName}; 25 25 group = config.users.groups.${target.groupName or user.group}; 26 + 27 + userId = toString user.uid; 28 + groupId = toString (group.gid or user.gid); 26 29 in 27 30 { 28 31 inherit exportPath; ··· 36 39 }; 37 40 38 41 nfsExport = '' 39 - "${exportPath}" *(rw,insecure,async,no_subtree_check,nohide,all_squash,anonuid=${toString user.uid},anongid=${toString group.gid}) 42 + "${exportPath}" *(rw,insecure,async,no_subtree_check,nohide,all_squash,anonuid=${userId},anongid=${groupId}) 40 43 ''; 41 44 }; 42 45