]> Git — Sourcephile - sourcephile-nix.git/blob - servers/losurdo/production/fileSystems.nix
losurdo: move everything from the SD card to the NVMe
[sourcephile-nix.git] / servers / losurdo / production / fileSystems.nix
1 { pkgs, lib, config, ... }:
2 {
3 imports = [
4 ../../../base/zfs.nix
5 ];
6
7 # The 32-bit host id of the machine, formatted as 8 hexadecimal characters.
8 # You should try to make this id unique among your machines.
9 # Manually generated with : head -c4 /dev/urandom | od -A none -t x4 | cut -d ' ' -f 2
10 networking.hostId = "69c40b03";
11
12 /*
13 # Enable the (OpenSolaris-compatible) ZFS auto-snapshotting service.
14 services.zfs.autoSnapshot = {
15 enable = true;
16 frequent = ;
17 hourly = ;
18 daily = ;
19 weekly = ;
20 monthly = ;
21 };
22 */
23
24 boot.loader.grub.devices = [
25 "/dev/disk/by-id/nvme-Samsung_SSD_970_EVO_Plus_250GB_S4EUNJ0N211426T"
26 ];
27
28 fileSystems."/boot" =
29 { device = "/dev/disk/by-partlabel/losurdo_nvme_boot";
30 fsType = "ext2";
31 };
32
33 fileSystems."/boot/efi" =
34 { device = "/dev/disk/by-partlabel/losurdo_nvme_efi";
35 fsType = "vfat";
36 };
37
38 swapDevices =
39 [ { device = "/dev/disk/by-partlabel/losurdo_nvme_swap";
40 randomEncryption = {
41 enable = true;
42 cipher = "aes-xts-plain64";
43 source = "/dev/urandom";
44 };
45 }
46 ];
47
48 fileSystems."/" =
49 { device = "losurdo_nvme/root";
50 fsType = "zfs";
51 };
52
53 fileSystems."/home" =
54 { device = "losurdo_nvme/home";
55 fsType = "zfs";
56 };
57
58 fileSystems."/nix" =
59 { device = "losurdo_nvme/nix";
60 fsType = "zfs";
61 };
62
63 fileSystems."/var" =
64 { device = "losurdo_nvme/var";
65 fsType = "zfs";
66 };
67
68 fileSystems."/var/cache" =
69 { device = "losurdo_nvme/var/cache";
70 fsType = "zfs";
71 };
72
73 fileSystems."/var/log" =
74 { device = "losurdo_nvme/var/log";
75 fsType = "zfs";
76 };
77
78 fileSystems."/var/tmp" =
79 { device = "losurdo_nvme/var/tmp";
80 fsType = "zfs";
81 };
82 }