nix-files/hosts/by-name/servo/fs.nix

86 lines
1.9 KiB
Nix
Raw Normal View History

{ ... }:
{
2023-01-06 10:04:51 +00:00
sane.persist.root-on-tmpfs = true;
fileSystems."/nix" = {
2022-11-29 02:20:18 +00:00
device = "/dev/disk/by-uuid/cc81cca0-3cc7-4d82-a00c-6243af3e7776";
fsType = "btrfs";
2022-11-29 02:20:18 +00:00
options = [
"compress=zstd"
"defaults"
];
};
fileSystems."/boot" = {
2022-11-29 02:20:18 +00:00
device = "/dev/disk/by-uuid/6EE3-4171";
fsType = "vfat";
};
2022-11-29 21:54:33 +00:00
# slow, external storage (for archiving, etc)
2023-01-06 10:04:51 +00:00
fileSystems."/mnt/persist/ext" = {
2022-11-29 21:54:33 +00:00
device = "/dev/disk/by-uuid/aa272cff-0fcc-498e-a4cb-0d95fb60631b";
fsType = "btrfs";
options = [
"compress=zstd"
"defaults"
];
};
2023-01-06 10:04:51 +00:00
sane.persist.stores."ext" = {
origin = "/mnt/persist/ext/persist";
storeDescription = "external HDD storage";
};
2023-01-06 10:04:51 +00:00
sane.fs."/mnt/persist/ext".mount = {};
sane.persist.sys.plaintext = [
2022-11-29 21:54:33 +00:00
# TODO: this is overly broad; only need media and share directories to be persisted
{ user = "colin"; group = "users"; path = "/var/lib/uninsane"; }
2022-11-29 21:54:33 +00:00
];
# make sure large media is stored to the HDD
sane.persist.sys.ext = [
{
user = "colin";
group = "users";
mode = "0777";
path = "/var/lib/uninsane/media/Videos";
}
{
user = "colin";
group = "users";
mode = "0777";
path = "/var/lib/uninsane/media/freeleech";
}
{
user = "colin";
group = "users";
mode = "0777";
path = "/var/lib/uninsane/media/datasets";
}
];
2022-11-29 21:54:33 +00:00
# btrfs doesn't easily support swapfiles
# swapDevices = [
# { device = "/nix/persist/swapfile"; size = 4096; }
# ];
# this can be a partition. create with:
# fdisk <dev>
# n
# <default partno>
# <start>
# <end>
# t
# <partno>
# 19 # set part type to Linux swap
# w # write changes
# mkswap -L swap <part>
2022-11-29 02:20:18 +00:00
# swapDevices = [
# {
# label = "swap";
# # TODO: randomEncryption.enable = true;
# }
# ];
}