44 lines
872 B
Nix
44 lines
872 B
Nix
{ config, ... }: {
|
|
|
|
zramSwap = {
|
|
enable = true;
|
|
algorithm = "zstd";
|
|
memoryPercent = 20;
|
|
};
|
|
|
|
fileSystems = {
|
|
"/" = {
|
|
fsType = "tmpfs";
|
|
options = [
|
|
"size=20%"
|
|
];
|
|
};
|
|
|
|
"/var" =
|
|
let
|
|
partConf = config.image.repart.partitions."var".repartConfig;
|
|
in
|
|
{
|
|
device = "/dev/disk/by-partuuid/${partConf.UUID}";
|
|
fsType = partConf.Format;
|
|
};
|
|
|
|
"/boot" =
|
|
let
|
|
partConf = config.image.repart.partitions."esp".repartConfig;
|
|
in
|
|
{
|
|
device = "/dev/disk/by-partuuid/${partConf.UUID}";
|
|
fsType = partConf.Format;
|
|
};
|
|
|
|
"/nix/store" =
|
|
let
|
|
partConf = config.image.repart.partitions."store".repartConfig;
|
|
in
|
|
{
|
|
device = "/dev/disk/by-partlabel/${partConf.Label}";
|
|
fsType = partConf.Format;
|
|
};
|
|
};
|
|
}
|