From 4a3abf5fe939c32d8c1c6e629205b1f3e0d0bada Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Wed, 17 Jan 2024 15:38:41 +0100 Subject: [PATCH] build-clan: force system override in secrets generators --- lib/build-clan/default.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/build-clan/default.nix b/lib/build-clan/default.nix index f3553aebc..8e536e35b 100644 --- a/lib/build-clan/default.nix +++ b/lib/build-clan/default.nix @@ -30,7 +30,7 @@ let (machineSettings.clanImports or [ ]); # TODO: remove default system once we have a hardware-config mechanism - nixosConfiguration = { system ? "x86_64-linux", name }: nixpkgs.lib.nixosSystem { + nixosConfiguration = { system ? "x86_64-linux", name, forceSystem ? false }: nixpkgs.lib.nixosSystem { modules = let settings = machineSettings name; @@ -45,7 +45,7 @@ let clanCore.clanName = clanName; clanCore.clanIcon = clanIcon; clanCore.clanDir = directory; - nixpkgs.hostPlatform = lib.mkDefault system; + nixpkgs.hostPlatform = if forceSystem then lib.mkForce system else lib.mkDefault system; # speeds up nix commands by using the nixpkgs from the host system (especially useful in VMs) nix.registry.nixpkgs.to = { @@ -75,7 +75,7 @@ let configsPerSystem = builtins.listToAttrs (builtins.map (system: lib.nameValuePair system - (lib.mapAttrs (name: _: nixosConfiguration { inherit name system; }) allMachines)) + (lib.mapAttrs (name: _: nixosConfiguration { inherit name system; forceSystem = true; }) allMachines)) supportedSystems); in {