From 466625488725700f88b09fa456927392ba336612 Mon Sep 17 00:00:00 2001 From: k3t Date: Tue, 23 Jun 2026 16:21:01 -0600 Subject: [PATCH] add NixNAS (Hyper-V) --- flake.nix | 37 +++++++++++++++++++++++++ hosts/NixNAS/configuration.nix | 19 +++++++++++++ hosts/NixNAS/hardware-configuration.nix | 18 ++++++++++++ 3 files changed, 74 insertions(+) create mode 100644 hosts/NixNAS/configuration.nix create mode 100644 hosts/NixNAS/hardware-configuration.nix diff --git a/flake.nix b/flake.nix index fa6fa9e..a90f838 100644 --- a/flake.nix +++ b/flake.nix @@ -117,6 +117,43 @@ } ]; + "NixNAS" = mkHost "x86_64-linux" [ + ./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 + + ./modules/sys/compat.nix + ./modules/sys/firewall.nix + + ./modules/sys/fs/btrfs.nix + ./modules/sys/fs/mounts/efi.nix + ./modules/sys/fs/mounts/root-btrfs.nix + ./modules/sys/fs/mounts/swap.nix + + ./modules/sys/hw/boot.nix + ./modules/sys/nix.nix + ./modules/sys/perf.nix + ./modules/sys/pkgs.nix + ./modules/sys/rc/openssh.nix + ./modules/sys/security.nix + ./modules/sys/shell.nix + ./modules/sys/stateversion.nix + ./modules/sys/sysctl.nix + ./modules/sys/time.nix + ./modules/sys/users/k3t.nix + + ./hosts/NixNAS/configuration.nix + spicetify-nix.nixosModules.spicetify + home-manager.nixosModules.home-manager + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.users.k3t = ./home/desktop.nix; + } + ]; + "IdeaPad" = mkHost "x86_64-linux" [ ./modules/audio/base.nix ./modules/audio/zeroconf.nix diff --git a/hosts/NixNAS/configuration.nix b/hosts/NixNAS/configuration.nix new file mode 100644 index 0000000..86027fa --- /dev/null +++ b/hosts/NixNAS/configuration.nix @@ -0,0 +1,19 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running ‘nixos-help’). + +{ config, pkgs, ... }: + +{ + imports = + [ # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; + + networking.hostName = "TheBlackBox"; + + users.users.k3t = { + packages = with pkgs; [ + ]; + }; +} diff --git a/hosts/NixNAS/hardware-configuration.nix b/hosts/NixNAS/hardware-configuration.nix new file mode 100644 index 0000000..6880f28 --- /dev/null +++ b/hosts/NixNAS/hardware-configuration.nix @@ -0,0 +1,18 @@ +# 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 = [ ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +}