update hardware generation in template

This commit is contained in:
jackjohn7 2026-04-12 03:13:34 -05:00
parent 93bff3aade
commit d4df258480
2 changed files with 13 additions and 1 deletions

1
templates/generic/.envrc Normal file
View file

@ -0,0 +1 @@
use flake

View file

@ -64,6 +64,7 @@ def host_templates(name: str) -> dict[Path, str]:
imports = [
self.nixosModules.{name}Hardware
];
system.stateVersion = "25.11";
}};
}}
"""
@ -77,7 +78,17 @@ def host_templates(name: str) -> dict[Path, str]:
{{ lib, pkgs, ... }}:
{{
config = {{
# Copy the generated hardware configuration here.
# If you're building a full system here, you'd likely want to just copy the hardware
# configuration generated by the NixOS installer. I've added some stuff here just so
# `nix flake check` passes on initialization of the flake and to show how it _could_
# look. You can find it here: `/etc/nixos/hardware-configuration.nix`
boot.loader.grub.devices = [ "/dev/sda" ];
fileSystems."/" = {{
device = "tmpfs";
fsType = "tmpfs";
}};
}};
}};
}}