refactor
This commit is contained in:
parent
7406d068b4
commit
ec45f12c12
16 changed files with 217 additions and 34 deletions
119
hosts/lilith-lab/hardware-configuration.nix
Normal file
119
hosts/lilith-lab/hardware-configuration.nix
Normal file
|
|
@ -0,0 +1,119 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"sd_mod"
|
||||
"bcache"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/0bb16b1d-eda8-4874-a79d-946888cf1c54";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=root" ];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/0bb16b1d-eda8-4874-a79d-946888cf1c54";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" ];
|
||||
};
|
||||
|
||||
fileSystems."/data" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/202B-F8D9";
|
||||
fsType = "vfat";
|
||||
options = [
|
||||
"fmask=0022"
|
||||
"dmask=0022"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/share" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=share"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/sync" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=sync"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/media" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=media"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/backups" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=backups"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/.snapshots" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=.snapshots"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/data/torrent" = {
|
||||
device = "/dev/disk/by-uuid/24022169-8d46-4684-9682-cfbd88e75e86";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=torrent"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
};
|
||||
|
||||
swapDevices = [ { device = "/dev/disk/by-uuid/b28e36ee-9a4d-4811-9ee6-6262881abb24"; } ];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp3s0.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wg0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue