Working config for fw13 amd

This commit is contained in:
Jurn Wubben 2025-02-14 19:40:27 +00:00
commit e706230566
48 changed files with 1812 additions and 0 deletions

61
hosts/default.nix Normal file
View file

@ -0,0 +1,61 @@
{
self,
inputs,
lib,
...
}: let
inherit (inputs.nixpkgs.lib) nixosSystem genAttrs;
specialArgs = {inherit inputs self;};
modules = [
inputs.hm.nixosModules.home-manager
../system
];
in {
flake = let
systems = [
"laptop"
];
in {
# Systems
nixosConfigurations = genAttrs systems (hostName:
nixosSystem {
inherit specialArgs;
modules =
modules
++ [
{
imports = [./${hostName}];
networking = {inherit hostName;};
}
];
});
};
perSystem = {
# Allows running 'nix run github:jsw08/NixOS' and it'll spin up a vm.
config,
pkgs,
...
}: let
nixos-vm = nixosSystem {
inherit specialArgs;
modules =
modules
++ [
{
networking.hostName = "vm";
nixpkgs.hostPlatform = pkgs.system;
boot.plymouth.enable = lib.mkForce false;
}
];
};
in {
apps.default = {
type = "app";
program = "${nixos-vm.config.system.build.vm}/bin/run-vm-vm";
};
};
}