Setup lappy for proper impermanance.
This commit is contained in:
@@ -48,6 +48,21 @@
|
|||||||
"noatime"
|
"noatime"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
"/root-blank" = {
|
||||||
|
mountOptions = [
|
||||||
|
"subvol=root-blank"
|
||||||
|
"nodatacow"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"/home" = {
|
||||||
|
mountpoint = "/home";
|
||||||
|
mountOptions = [
|
||||||
|
"subvol=home"
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
};
|
||||||
"/nix" = {
|
"/nix" = {
|
||||||
mountpoint = "/nix";
|
mountpoint = "/nix";
|
||||||
mountOptions = [
|
mountOptions = [
|
||||||
@@ -72,6 +87,23 @@
|
|||||||
"noatime"
|
"noatime"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
"/lib" = {
|
||||||
|
mountpoint = "/var/lib";
|
||||||
|
mountOptions = [
|
||||||
|
"subvol=lib"
|
||||||
|
"compress=zstd"
|
||||||
|
"noatime"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"/persist/swap" = {
|
||||||
|
mountpoint = "/persist/swap";
|
||||||
|
mountOptions = [
|
||||||
|
"subvol=swap"
|
||||||
|
"noatime"
|
||||||
|
"nodatacow"
|
||||||
|
"compress=no"
|
||||||
|
];
|
||||||
|
swap.swapfile.size = "18G";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -81,6 +113,8 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
fileSystems."/nix/persist".neededForBoot = true;
|
};
|
||||||
|
fileSystems."/persist".neededForBoot = true;
|
||||||
fileSystems."/var/log".neededForBoot = true;
|
fileSystems."/var/log".neededForBoot = true;
|
||||||
|
fileSystems."/var/lib".neededForBoot = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,6 +6,12 @@
|
|||||||
options = [ "subvol=root" "compress=zstd" "noatime" ];
|
options = [ "subvol=root" "compress=zstd" "noatime" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
fileSystems."/home" =
|
||||||
|
{ device = "/dev/mapper/cryptroot";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=nix" "compress=zstd" "noatime" ];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/nix" =
|
fileSystems."/nix" =
|
||||||
{ device = "/dev/mapper/cryptroot";
|
{ device = "/dev/mapper/cryptroot";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
@@ -19,7 +25,14 @@
|
|||||||
neededForBoot = true;
|
neededForBoot = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/nix/persist" =
|
fileSystems."/var/lib" =
|
||||||
|
{ device = "/dev/mapper/cryptroot";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=lib" "compress=zstd" "noatime" ];
|
||||||
|
neededForBoot = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/persist" =
|
||||||
{ device = "/dev/mapper/cryptroot";
|
{ device = "/dev/mapper/cryptroot";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = [ "subvol=persist" "compress=zstd" "noatime" ];
|
options = [ "subvol=persist" "compress=zstd" "noatime" ];
|
||||||
@@ -32,9 +45,15 @@
|
|||||||
options = [ "fmask=0077" "dmask=0077" ];
|
options = [ "fmask=0077" "dmask=0077" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
fileSystems."/persist/swap" =
|
||||||
|
{ device = "/dev/mapper/cryptroot";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=swap" "noatime" "nodatacow" "compress=no" ];
|
||||||
|
};
|
||||||
|
|
||||||
swapDevices = [{
|
swapDevices = [{
|
||||||
device = "/swapfile";
|
device = "/persist/swap/swapfile";
|
||||||
size = 16 * 1024;
|
size = 18 * 1024;
|
||||||
}];
|
}];
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user