hosts: define hostPlatform in defined systems

instead of getting them impurely from `builtins.currentSystem`
This commit is contained in:
Wroclaw 2025-04-01 15:37:03 +02:00
parent e3264f1451
commit 00cbc505f3
4 changed files with 6 additions and 0 deletions

View file

@ -83,6 +83,8 @@
OLLAMA_HOST = "127.0.0.1:${builtins.toString config.services.ollama.port}"; OLLAMA_HOST = "127.0.0.1:${builtins.toString config.services.ollama.port}";
}; };
nixpkgs.hostPlatform = "x86_64-linux";
system.stateVersion = "23.05"; system.stateVersion = "23.05";
}; };
} }

View file

@ -52,6 +52,8 @@
lidSwitchExternalPower = "lock"; lidSwitchExternalPower = "lock";
}; };
nixpkgs.hostPlatform = "x86_64-linux";
system.stateVersion = "23.11"; system.stateVersion = "23.11";
}; };
} }

View file

@ -20,5 +20,6 @@
virtualisation.forwardPorts = [ virtualisation.forwardPorts = [
{ from = "host"; host.port = 2222; guest.port = 22; } { from = "host"; host.port = 2222; guest.port = 22; }
]; ];
nixpkgs.hostPlatform = "x86_64-linux";
}; };
} }

View file

@ -38,6 +38,7 @@ self = {
nixosSystem = import "${inputs.nixpkgs}/nixos/lib/eval-config.nix"; nixosSystem = import "${inputs.nixpkgs}/nixos/lib/eval-config.nix";
mkNixosSystem = path: nixosSystem { mkNixosSystem = path: nixosSystem {
inherit lib; inherit lib;
system = null;
modules = [ modules = [
path path
{ {