2024-10-15 17:46:44 -04:00
|
|
|
{ config, lib, pkgs, modulesPath, ... }:
|
2024-08-24 22:16:51 -04:00
|
|
|
{
|
|
|
|
boot = {
|
|
|
|
blacklistedKernelModules = [
|
|
|
|
"pcspkr"
|
2024-10-22 07:51:39 -04:00
|
|
|
];
|
2024-08-24 22:16:51 -04:00
|
|
|
initrd = {
|
|
|
|
availableKernelModules = [
|
|
|
|
"xhci_pci"
|
2024-10-20 20:29:38 -04:00
|
|
|
"ehci_pci"
|
|
|
|
"ahci"
|
|
|
|
"nvme"
|
|
|
|
"usbhid"
|
|
|
|
"sd_mod"
|
|
|
|
"sr_mod"
|
2024-08-24 22:16:51 -04:00
|
|
|
];
|
|
|
|
kernelModules = [
|
|
|
|
"kvm-intel"
|
|
|
|
];
|
|
|
|
};
|
2024-10-09 03:36:08 -04:00
|
|
|
swraid = {
|
|
|
|
enable = true;
|
2024-11-13 04:10:42 -05:00
|
|
|
mdadmConf = "MAILADDR contact@${config.domains.jim2}";
|
2024-10-09 03:36:08 -04:00
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
|
|
|
|
2024-10-24 05:41:55 -04:00
|
|
|
# Main root
|
2024-08-24 22:16:51 -04:00
|
|
|
fileSystems = {
|
2024-10-22 07:51:39 -04:00
|
|
|
"/" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-22 07:51:39 -04:00
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@" ];
|
|
|
|
};
|
|
|
|
"/home" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-22 07:51:39 -04:00
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@home" ];
|
|
|
|
};
|
|
|
|
"/nix" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-22 07:51:39 -04:00
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@nix" ];
|
|
|
|
};
|
|
|
|
"/var" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-22 07:51:39 -04:00
|
|
|
fsType = "btrfs";
|
|
|
|
options = [ "subvol=@var" ];
|
|
|
|
};
|
2024-10-24 05:41:55 -04:00
|
|
|
"/srv/minecraft" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-10-24 06:20:31 -04:00
|
|
|
options = [ "subvol=@minecraft" "compress=zstd" ];
|
2024-10-24 05:41:55 -04:00
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
"/boot" = {
|
2024-10-22 07:51:39 -04:00
|
|
|
device = "/dev/disk/by-uuid/CD94-1D3F";
|
2024-08-24 22:16:51 -04:00
|
|
|
fsType = "vfat";
|
2024-10-22 07:51:39 -04:00
|
|
|
options = [ "fmask=0022" "dmask=0022" ];
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
2024-10-07 11:42:34 -04:00
|
|
|
|
2024-11-02 17:19:40 -04:00
|
|
|
# Files
|
2024-10-24 05:41:55 -04:00
|
|
|
"/export/JimboNFS/Downloads" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-10-24 06:20:31 -04:00
|
|
|
options = [ "subvol=@downloads" "compress=zstd" ];
|
2024-08-30 14:15:38 -04:00
|
|
|
};
|
2024-10-24 05:41:55 -04:00
|
|
|
"/export/JimboNFS/Documents" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-10-24 06:20:31 -04:00
|
|
|
options = [ "subvol=@docs" "compress=zstd" ];
|
2024-10-24 05:41:55 -04:00
|
|
|
};
|
2024-11-02 17:19:40 -04:00
|
|
|
|
|
|
|
# Media
|
2024-10-24 05:41:55 -04:00
|
|
|
"/export/JimboNFS/Photos" = {
|
2024-11-02 17:19:40 -04:00
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-10-24 06:20:31 -04:00
|
|
|
options = [ "subvol=@photos" "compress=zstd" ];
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
2024-11-02 17:19:40 -04:00
|
|
|
"/export/JimboNFS/Videos" = {
|
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-11-02 17:19:40 -04:00
|
|
|
options = [ "subvol=@videos" "compress=zstd" ];
|
2024-10-24 05:41:55 -04:00
|
|
|
};
|
2024-11-02 17:19:40 -04:00
|
|
|
|
|
|
|
# Music
|
|
|
|
"/export/JimboNFS/Music" = {
|
|
|
|
device = "/dev/server/root";
|
2024-10-24 05:41:55 -04:00
|
|
|
fsType = "btrfs";
|
2024-11-02 17:19:40 -04:00
|
|
|
options = [ "subvol=@music" "compress=zstd" ];
|
2024-09-10 14:45:28 -04:00
|
|
|
};
|
2024-08-24 22:16:51 -04:00
|
|
|
};
|
2024-09-10 15:54:45 -04:00
|
|
|
|
2024-10-24 05:41:55 -04:00
|
|
|
|
2024-08-24 22:16:51 -04:00
|
|
|
swapDevices = [
|
2024-11-02 17:19:40 -04:00
|
|
|
{ device = "/dev/server/root/swap"; }
|
2024-08-24 22:16:51 -04:00
|
|
|
];
|
|
|
|
|
2024-10-09 03:36:08 -04:00
|
|
|
networking.useDHCP = lib.mkDefault true;
|
2024-09-22 14:46:51 -04:00
|
|
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
2024-10-22 07:51:39 -04:00
|
|
|
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
2024-08-24 22:16:51 -04:00
|
|
|
}
|