From 47910ab3a0e4d30678a4840867def9f90535570a Mon Sep 17 00:00:00 2001 From: Danilo Reyes Date: Tue, 3 Feb 2026 17:52:53 -0600 Subject: [PATCH] vps hardware --- hosts/vps/configuration.nix | 1 + hosts/vps/hardware-configuration.nix | 41 ++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 hosts/vps/hardware-configuration.nix diff --git a/hosts/vps/configuration.nix b/hosts/vps/configuration.nix index 2cb491e..a0a5c7f 100644 --- a/hosts/vps/configuration.nix +++ b/hosts/vps/configuration.nix @@ -5,6 +5,7 @@ }: { imports = [ + ./hardware-configuration.nix ../../config/base.nix ]; my = { diff --git a/hosts/vps/hardware-configuration.nix b/hosts/vps/hardware-configuration.nix new file mode 100644 index 0000000..f68c714 --- /dev/null +++ b/hosts/vps/hardware-configuration.nix @@ -0,0 +1,41 @@ +{ + lib, + modulesPath, + ... +}: +{ + imports = [ (modulesPath + "/profiles/qemu-guest.nix") ]; + boot = { + kernelModules = [ ]; + extraModulePackages = [ ]; + kernelParams = [ "console=ttyS0,19200n8" ]; + initrd.availableKernelModules = [ + "virtio_pci" + "virtio_scsi" + "ahci" + "sd_mod" + ]; + loader = { + timeout = 10; + grub = { + device = "nodev"; + forceInstall = true; + extraConfig = '' + serial --speed=19200 --unit=0 --word=8 --parity=no --stop=1; + terminal_input serial; + terminal_output serial + ''; + }; + }; + }; + fileSystems."/" = { + device = "/dev/disk/by-uuid/f222513b-ded1-49fa-b591-20ce86a2fe7f"; + fsType = "ext4"; + }; + swapDevices = [ + { + device = "/dev/disk/by-uuid/f1408ea6-59a0-11ed-bc9d-525400000001"; + } + ]; + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; +}