summaryrefslogtreecommitdiff
path: root/hosts/kaworu
diff options
context:
space:
mode:
authorFreya Murphy <freya@freyacat.org>2025-06-23 20:36:11 -0400
committerFreya Murphy <freya@freyacat.org>2025-06-23 20:36:11 -0400
commit70e9534e78f5a9e1ab05da2b42dbbbdad9ce9ead (patch)
tree9bfe266c73c822bf2a1f56dfad43cf578c0b7441 /hosts/kaworu
parentadd sshd (diff)
downloaddotfiles-nix-70e9534e78f5a9e1ab05da2b42dbbbdad9ce9ead.tar.gz
dotfiles-nix-70e9534e78f5a9e1ab05da2b42dbbbdad9ce9ead.tar.bz2
dotfiles-nix-70e9534e78f5a9e1ab05da2b42dbbbdad9ce9ead.zip
move hosts hardware configs into own hardware.nix's
Diffstat (limited to 'hosts/kaworu')
-rw-r--r--hosts/kaworu/default.nix50
-rw-r--r--hosts/kaworu/hardware.nix47
2 files changed, 51 insertions, 46 deletions
diff --git a/hosts/kaworu/default.nix b/hosts/kaworu/default.nix
index cab2e3d..2ac1186 100644
--- a/hosts/kaworu/default.nix
+++ b/hosts/kaworu/default.nix
@@ -15,6 +15,10 @@ inputs.nixpkgs.lib.nixosSystem rec {
../../programs
../../system
{
+ imports = [
+ ./hardware.nix
+ ];
+
# options
hostName = "kaworu";
monitors = [
@@ -23,52 +27,6 @@ inputs.nixpkgs.lib.nixosSystem rec {
scale = 1.0;
}
];
-
- # hardware
- hardware.graphics.enable = true;
- hardware.bluetooth.enable = true;
-
- # bootloader
- boot.loader.systemd-boot.enable = true;
- boot.loader.efi = {
- canTouchEfiVariables = true;
- efiSysMountPoint = "/boot/efi";
- };
-
- # kernel modules
- boot.initrd.availableKernelModules = [
- "xhci_pci"
- "ahci"
- "usb_storage"
- "usbhid"
- "sd_mod"
- ];
- boot.initrd.kernelModules = [];
- boot.kernelModules = ["kvm-amd"];
- boot.extraModulePackages = [];
-
- # firmware
- hardware.enableRedistributableFirmware = true;
- hardware.cpu.amd.updateMicrocode = true;
-
- # luks device
- boot.initrd.luks.devices."root".device = "/dev/disk/by-uuid/89257280-202b-4565-b832-89f160d5e4e2";
-
- # root
- fileSystems."/" = {
- device = "/dev/disk/by-uuid/4906f0dd-b036-40fc-9a3f-0d031dbc2513";
- fsType = "btrfs";
- };
-
- # boot
- fileSystems."/boot/efi" = {
- device = "/dev/disk/by-uuid/099A-D668";
- fsType = "vfat";
- options = ["fmask=0022" "dmask=0022"];
- };
-
- # swap
- swapDevices = [];
}
];
}
diff --git a/hosts/kaworu/hardware.nix b/hosts/kaworu/hardware.nix
new file mode 100644
index 0000000..b236890
--- /dev/null
+++ b/hosts/kaworu/hardware.nix
@@ -0,0 +1,47 @@
+{...}: {
+ # hardware
+ hardware.graphics.enable = true;
+ hardware.bluetooth.enable = true;
+
+ # bootloader
+ boot.loader.systemd-boot.enable = true;
+ boot.loader.efi = {
+ canTouchEfiVariables = true;
+ efiSysMountPoint = "/boot/efi";
+ };
+
+ # kernel modules
+ boot.initrd.availableKernelModules = [
+ "xhci_pci"
+ "ahci"
+ "usb_storage"
+ "usbhid"
+ "sd_mod"
+ ];
+ boot.initrd.kernelModules = [];
+ boot.kernelModules = ["kvm-amd"];
+ boot.extraModulePackages = [];
+
+ # firmware
+ hardware.enableRedistributableFirmware = true;
+ hardware.cpu.amd.updateMicrocode = true;
+
+ # luks device
+ boot.initrd.luks.devices."root".device = "/dev/disk/by-uuid/89257280-202b-4565-b832-89f160d5e4e2";
+
+ # root
+ fileSystems."/" = {
+ device = "/dev/disk/by-uuid/4906f0dd-b036-40fc-9a3f-0d031dbc2513";
+ fsType = "btrfs";
+ };
+
+ # boot
+ fileSystems."/boot/efi" = {
+ device = "/dev/disk/by-uuid/099A-D668";
+ fsType = "vfat";
+ options = ["fmask=0022" "dmask=0022"];
+ };
+
+ # swap
+ swapDevices = [];
+}