nixos-config/systems/nasty/drives.nix

167 lines
5.5 KiB
Nix
Raw Normal View History

2025-11-24 10:55:54 +01:00
{ pkgs, ... }:
2025-06-06 10:13:45 +02:00
let
btrfsOpt = [ "compress-force=zstd" "nofail" "x-systemd.mount-timeout=10m" ];
2025-11-10 14:22:01 +01:00
btrfsNoComp = [ "nofail" "x-systemd.mount-timeout=10m" ];
2025-06-06 10:13:45 +02:00
in
2024-08-28 00:00:10 +02:00
{
2025-11-24 10:55:54 +01:00
environment.systemPackages = with pkgs; [
openssl
];
2024-08-28 00:00:10 +02:00
environment.etc.crypttab = {
text = ''
2025-06-06 10:13:45 +02:00
1EJZN6MZ UUID=da1abbcf-69ef-4bbf-847f-5df0c2a321f9 /var/lib/keyfiles/da1abbcf-69ef-4bbf-847f-5df0c2a321f9 nofail
1EKR513Z UUID=9dfd833d-b79f-478b-9c07-e6730f88b02f /var/lib/keyfiles/9dfd833d-b79f-478b-9c07-e6730f88b02f nofail
1EKVK21Z UUID=7d1b1146-a50e-405e-8d3e-df0d1fbc9451 /var/lib/keyfiles/7d1b1146-a50e-405e-8d3e-df0d1fbc9451 nofail
2024-08-28 00:00:10 +02:00
43P0A00AFJDH UUID=eff697b4-86bc-4a0e-833f-cc40e6aa001e /var/lib/keyfiles/eff697b4-86bc-4a0e-833f-cc40e6aa001e nofail
2025-11-24 10:55:54 +01:00
43P0A00FFJDH UUID=b6644f6f-32f6-42e3-a247-fc8314620a12 /var/lib/keyfiles/b6644f6f-32f6-42e3-a247-fc8314620a12 nofail
2025-06-06 10:13:45 +02:00
53F0A0SBFJDH UUID=d228e44f-fe1f-4eee-8415-289583ddec99 /var/lib/keyfiles/d228e44f-fe1f-4eee-8415-289583ddec99 nofail
53G0A2AXFJDH UUID=dd66940c-aa6e-460a-9e55-7dd08247a792 /var/lib/keyfiles/dd66940c-aa6e-460a-9e55-7dd08247a792 nofail
2024-08-28 00:00:10 +02:00
53J0A016FJDH UUID=95f84b21-d3d3-4241-8a9b-5ac46afea1e1 /var/lib/keyfiles/95f84b21-d3d3-4241-8a9b-5ac46afea1e1 nofail
2025-11-10 14:22:01 +01:00
92F0A079FJDH UUID=adf0a919-3ff2-4508-86af-9bc94573a484 /var/lib/keyfiles/adf0a919-3ff2-4508-86af-9bc94573a484 nofail
2025-06-06 10:13:45 +02:00
X2N0A0AXFJDH UUID=7b46d2e3-09da-4ef6-987f-6ffcabf79537 /var/lib/keyfiles/7b46d2e3-09da-4ef6-987f-6ffcabf79537 nofail
2025-11-24 10:55:54 +01:00
X2N0A0AZFJDH UUID=9bec2830-fed7-4235-ac27-7af470d2981b /var/lib/keyfiles/9bec2830-fed7-4235-ac27-7af470d2981b nofail
2025-06-06 10:13:45 +02:00
ZA1D9307 UUID=79f2d993-6862-4f9c-ba2d-88f49286e356 /var/lib/keyfiles/79f2d993-6862-4f9c-ba2d-88f49286e356 nofail
ZVV0688G UUID=8a14aa76-5138-4cd0-8f31-0aafe63e870b /var/lib/keyfiles/8a14aa76-5138-4cd0-8f31-0aafe63e870b nofail
ZVV072JR UUID=416f1016-b849-4bc8-a078-4b1426788c6c /var/lib/keyfiles/416f1016-b849-4bc8-a078-4b1426788c6c nofail
2025-11-10 14:22:01 +01:00
ZXA0FSKT UUID=4f1e92cc-1267-4671-b943-99481ea2a7b5 /var/lib/keyfiles/4f1e92cc-1267-4671-b943-99481ea2a7b5 nofail
ZXA0MNRB UUID=64161475-e328-4a59-98d5-117d724693cf /var/lib/keyfiles/64161475-e328-4a59-98d5-117d724693cf nofail
2024-08-28 00:00:10 +02:00
'';
#unused
};
fileSystems = {
"/" = {
device = "/dev/disk/by-uuid/ad716602-9e0d-4c07-9fb5-e15cb6df3004";
fsType = "ext4";
};
"/boot/efi" = {
device = "/dev/disk/by-uuid/2427-55B1";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
"/mnt/drives/1EJZN6MZ" = {
label = "1EJZN6MZ";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/1EKR513Z" = {
label = "1EKR513Z";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/1EKVK21Z" = {
label = "1EKVK21Z";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
2025-11-10 14:22:01 +01:00
#"/mnt/drives/53F0A0SBFJDH" = {
# label = "53F0A0SBFJDH";
# fsType = "btrfs";
# options = btrfsOpt;
#};
2024-08-28 00:00:10 +02:00
"/mnt/drives/53G0A2AXFJDH" = {
label = "53G0A2AXFJDH";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/53J0A016FJDH" = {
label = "53J0A016FJDH";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/92F0A079FJDH" = {
label = "92F0A079FJDH";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/43P0A00FFJDH" = {
label = "43P0A00FFJDH";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/43P0A00AFJDH" = {
label = "43P0A00AFJDH";
fsType = "btrfs";
2025-11-10 14:22:01 +01:00
options = btrfsNoComp;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/X2N0A0AXFJDH" = {
label = "X2N0A0AXFJDH";
2025-06-06 10:13:45 +02:00
fsType = "btrfs";
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/X2N0A0AZFJDH" = {
label = "X2N0A0AZFJDH";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
"/mnt/drives/ZA1D9307" = {
label = "ZA1D9307";
fsType = "btrfs";
2025-06-06 10:13:45 +02:00
options = btrfsOpt;
};
"/mnt/drives/ZVV0688G" = {
label = "ZVV0688G";
fsType = "btrfs";
options = btrfsOpt;
};
"/mnt/drives/ZVV072JR" = {
label = "ZVV072JR";
fsType = "btrfs";
options = btrfsOpt;
2024-08-28 00:00:10 +02:00
};
2025-11-10 14:22:01 +01:00
"/mnt/drives/ZXA0FSKT" = {
label = "ZXA0FSKT-lv0";
fsType = "btrfs";
options = btrfsOpt;
};
"/mnt/drives/ZXA0MNRB" = {
label = "ZXA0MNRB-lv0";
fsType = "btrfs";
options = btrfsNoComp;
};
2024-08-28 00:00:10 +02:00
"/mnt/mergerfs" = {
2025-11-24 10:55:54 +01:00
device = "/mnt/drives/ZVV0688G:/mnt/drives/ZVV072JR:/mnt/drives/ZXA0FSKT:/mnt/drives/92F0A079FJDH:/mnt/drives/53G0A2AXFJDH:/mnt/drives/53J0A016FJDH:/mnt/drives/X2N0A0AXFJDH:/mnt/drives/X2N0A0AZFJDH:/mnt/drives/ZA1D9307:/mnt/drives/1EJZN6MZ:/mnt/drives/1EKR513Z:/mnt/drives/1EKVK21Z";
2024-08-28 00:00:10 +02:00
fsType = "fuse.mergerfs";
options = [ "cache.files=full,,dropcacheonclose=true,category.create=mfs" "nofail" ];
2025-11-24 10:55:54 +01:00
depends = [ "/mnt/drives/ZVV0688G" "/mnt/drives/ZVV072JR" "/mnt/drives/92F0A079FJDH" "/mnt/drives/53G0A2AXFJDH" "/mnt/drives/53J0A016FJDH" "/mnt/drives/X2N0A0AXFJDH" "/mnt/drives/X2N0A0AZFJDH" "/mnt/drives/ZA1D9307" "/mnt/drives/1EJZN6MZ" "/mnt/drives/1EKR513Z" "/mnt/drives/1EKVK21Z" "/mnt/drives/ZXA0FSKT" ];
2024-08-28 00:00:10 +02:00
};
#"/mnt/box" = {
# device = "seedbox:";
# fsType = "fuse.rclone";
# options = [ "user_id=1000" "group_id=100" ];
#};
};
services.nfs.server = {
enable = true;
exports = ''
/mnt/mergerfs 100.64.0.13(no_subtree_check,fsid=0)
2025-06-06 10:13:45 +02:00
/mnt/mergerfs 100.64.0.7(no_subtree_check,fsid=0)
2024-08-28 00:00:10 +02:00
'';
};
}
# vim: set et ts=2 sw=2 ai: