]> Git — Sourcephile - sourcephile-nix.git/blob - hosts/mermet/fileSystems.nix
private: remove
[sourcephile-nix.git] / hosts / mermet / fileSystems.nix
1 { pkgs, lib, config, inputs, hostName, ... }:
2 {
3 imports = [
4 (inputs.julm-nix + "/nixos/profiles/zfs.nix")
5 ];
6
7 /*
8 fileSystems."/boot" =
9 { device = "bpool/boot";
10 fsType = "zfs";
11 };
12 */
13 fileSystems."/" = {
14 device = "rpool/root";
15 fsType = "zfs"; # TODO: options = [ "zfsutil" ];
16 };
17
18 # This will automatically load the zfs password prompt on login
19 # and kill the other prompt so boot can continue
20 # The pkill zfs kills the zfs load-key from the console
21 # allowing the boot to continue.
22 boot.initrd.network.postCommands = ''
23 echo >>/root/.profile "zfs load-key rpool && pkill zfs"
24 '';
25 boot.zfs.requestEncryptionCredentials = lib.mkForce [ "rpool" ];
26 #boot.zfs.requestEncryptionCredentials = [ hostName ];
27
28 fileSystems."/home" =
29 { device = "rpool/home";
30 fsType = "zfs";
31 };
32
33 fileSystems."/home/julm" =
34 { device = "rpool/home/julm";
35 fsType = "zfs";
36 };
37
38 fileSystems."/home/julm/log" =
39 { device = "rpool/home/julm/log";
40 fsType = "zfs";
41 };
42
43 fileSystems."/home/julm/mail" =
44 { device = "rpool/home/julm/mail";
45 fsType = "zfs";
46 };
47
48 fileSystems."/nix" =
49 { device = "rpool/nix";
50 fsType = "zfs";
51 };
52
53 fileSystems."/var" =
54 { device = "rpool/var";
55 fsType = "zfs";
56 };
57
58 fileSystems."/var/cache" =
59 { device = "rpool/var/cache";
60 fsType = "zfs";
61 };
62
63 fileSystems."/var/log" =
64 { device = "rpool/var/log";
65 fsType = "zfs";
66 };
67
68 fileSystems."/var/tmp" =
69 { device = "rpool/var/tmp";
70 fsType = "zfs";
71 };
72
73 fileSystems."/var/www" =
74 { device = "rpool/var/www";
75 fsType = "zfs";
76 };
77 }