From e43fc615b120b0214c18fad80f374d6f49d57723 Mon Sep 17 00:00:00 2001 From: TheWanderingCrow Date: Wed, 2 Jul 2025 15:02:38 -0400 Subject: [PATCH] add handlerone --- home/crow/HandlerOne.nix | 5 ++ hosts/nixos/HandlerOne/default.nix | 51 +++++++++++++++++++ .../HandlerOne/hardware-configuration.nix | 20 ++++++++ 3 files changed, 76 insertions(+) create mode 100644 home/crow/HandlerOne.nix create mode 100644 hosts/nixos/HandlerOne/hardware-configuration.nix diff --git a/home/crow/HandlerOne.nix b/home/crow/HandlerOne.nix new file mode 100644 index 0000000..9b2069a --- /dev/null +++ b/home/crow/HandlerOne.nix @@ -0,0 +1,5 @@ +{...}: { + imports = [ + common/core + ]; +} diff --git a/hosts/nixos/HandlerOne/default.nix b/hosts/nixos/HandlerOne/default.nix index c15d8e1..a11cc11 100644 --- a/hosts/nixos/HandlerOne/default.nix +++ b/hosts/nixos/HandlerOne/default.nix @@ -3,3 +3,54 @@ # HandlerOne - m710q # # # ###################### +{ + inputs, + lib, + pkgs, + ... +}: { + imports = lib.flatten [ + # Hardware + ./hardware-configuration.nix + + # Disks + inputs.disko.nixosModules.disko + (lib.custom.relativeToRoot "hosts/common/disks/btrfs-disk.nix") + { + _module.args = { + disk = "/dev/nvme0n1"; + withSwap = true; + swapSize = "8"; + }; + } + + # Misc + + (map lib.custom.relativeToRoot [ + # Required configs + "hosts/common/core" + + # Optional configs + "hosts/common/optional/keyd.nix" + ]) + ]; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + + hostSpec = { + hostName = "HandlerOne"; + persistFolder = "/persist"; + }; + + networking = { + networkmanager.enable = true; + enableIPv6 = false; + }; + + boot.loader = { + systemd-boot.enable = true; + efi = { + canTouchEfiVariables = true; + }; + }; +} diff --git a/hosts/nixos/HandlerOne/hardware-configuration.nix b/hosts/nixos/HandlerOne/hardware-configuration.nix new file mode 100644 index 0000000..737a70b --- /dev/null +++ b/hosts/nixos/HandlerOne/hardware-configuration.nix @@ -0,0 +1,20 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ + config, + lib, + pkgs, + modulesPath, + ... +}: { + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod"]; + boot.supportedFilesystems = ["zfs"]; + boot.initrd.kernelModules = []; + boot.kernelModules = []; + boot.extraModulePackages = []; +}