main
nix 61 lines 1.14 KB
Raw
1 {
2 disk = {
3 main = {
4 device = "/dev/sda";
5 type = "disk";
6 content = {
7 type = "gpt";
8 partitions = {
9 esp = {
10 type = "EF00";
11 size = "1024M";
12 content = {
13 type = "filesystem";
14 format = "vfat";
15 mountpoint = "/efi";
16 };
17 };
18 root = {
19 size = "100%";
20 content = {
21 type = "zfs";
22 pool = "zroot";
23 };
24 };
25 };
26 };
27 };
28 };
29
30 zpool.zroot = {
31 type = "zpool";
32 options = {
33 # smartctl --all /dev/sda
34 # Logical block size: 512 bytes
35 ashift = "9";
36 };
37 rootFsOptions = {
38 acltype = "posixacl";
39 compression = "zstd";
40 mountpoint = "none";
41 xattr = "sa";
42 };
43 datasets = {
44 "root" = {
45 type = "zfs_fs";
46 mountpoint = "/";
47 };
48 "nix" = {
49 type = "zfs_fs";
50 mountpoint = "/nix";
51 };
52 "reserved" = {
53 type = "zfs_fs";
54 options = {
55 canmount = "off";
56 refreservation = "1G";
57 };
58 };
59 };
60 };
61 }