From 505c3629fc038d603ed9a0da45dc485f180dd6a9 Mon Sep 17 00:00:00 2001 From: k3t Date: Mon, 1 Jun 2026 18:32:49 -0600 Subject: [PATCH] fix hardware config for board, move some things around --- flake.nix | 4 +++- hosts/board/hardware-configuration.nix | 22 ++++++++++------------ modules/pi-common.nix | 1 - modules/vps-aarch64-common.nix | 12 ------------ 4 files changed, 13 insertions(+), 26 deletions(-) delete mode 100755 modules/vps-aarch64-common.nix diff --git a/flake.nix b/flake.nix index 1186ad5..a68fa84 100755 --- a/flake.nix +++ b/flake.nix @@ -60,6 +60,7 @@ ./modules/gui/services/xdg.nix ./modules/net/services/avahi.nix + ./modules/net/services/fail2ban.nix ./modules/net/services/networkmanager.nix ./modules/net/services/printing.nix ./modules/net/services/tailscale.nix @@ -108,6 +109,7 @@ ./modules/gui/services/xdg.nix ./modules/net/services/avahi.nix + ./modules/net/services/fail2ban.nix ./modules/net/services/networkmanager.nix ./modules/net/services/printing.nix ./modules/net/services/tailscale.nix @@ -166,6 +168,7 @@ # } #]; "nixcloud" = mkHost "x86_64-linux" [ + ./modules/net/services/fail2ban.nix ./modules/net/services/networkmanager.nix ./modules/net/services/tailscale.nix ./modules/sys/compat.nix @@ -182,7 +185,6 @@ ./modules/sys/stateversion.nix ./modules/sys/tz.nix ./modules/sys/users.nix - ./modules/vps-aarch64-common.nix ./hosts/nixcloud/configuration.nix home-manager.nixosModules.home-manager { diff --git a/hosts/board/hardware-configuration.nix b/hosts/board/hardware-configuration.nix index fc8e8ae..6e9c796 100755 --- a/hosts/board/hardware-configuration.nix +++ b/hosts/board/hardware-configuration.nix @@ -8,27 +8,25 @@ [ (modulesPath + "/installer/scan/not-detected.nix") ]; - fileSystems."/" = - { device = "/dev/disk/by-label/NixOS"; - fsType = "btrfs"; - options = [ "subvol=@" ]; - }; + boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-amd" ]; + boot.extraModulePackages = [ ]; - fileSystems."/home" = - { device = "/dev/disk/by-label/NixOS"; + fileSystems."/" = + { device = "/dev/disk/by-uuid/b17472f2-bf78-4850-abe1-f324dbb4d361"; fsType = "btrfs"; - options = [ "subvol=@home" ]; }; fileSystems."/boot" = - { device = "/dev/disk/by-uuid/E0C2-A3A3"; + { device = "/dev/disk/by-uuid/894A-AE22"; fsType = "vfat"; options = [ "fmask=0077" "dmask=0077" ]; }; - #swapDevices = - # [ { device = "/dev/disk/by-uuid/fe32f9af-3382-4505-90e3-aaf1c41bf5d4"; } - # ]; + swapDevices = + [ { device = "/dev/disk/by-uuid/9d20f606-cd87-40e1-adad-c470acf0a66a"; } + ]; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; diff --git a/modules/pi-common.nix b/modules/pi-common.nix index e853c3b..87899fc 100755 --- a/modules/pi-common.nix +++ b/modules/pi-common.nix @@ -18,7 +18,6 @@ }; networking.networkmanager.wifi.powersave = false; - boot.loader.grub.enable = false; boot.loader.generic-extlinux-compatible.enable = true; environment.systemPackages = with pkgs; [ diff --git a/modules/vps-aarch64-common.nix b/modules/vps-aarch64-common.nix deleted file mode 100755 index a21b93e..0000000 --- a/modules/vps-aarch64-common.nix +++ /dev/null @@ -1,12 +0,0 @@ -{ pkgs, ... }: { - - #environment.systemPackages = with pkgs; [ - #]; - - services.fail2ban.enable = true; - services.openssh = { - enable = true; - settings.PasswordAuthentication = true; - }; - -}