From e8d2ae2d7e2cdfdce82a6ebfe81a99b4ed675e1d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Tue, 6 May 2025 09:26:59 +0200 Subject: [PATCH 1/2] fix incorrect target host when build host is set --- pkgs/clan-cli/clan_cli/machines/update.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/clan-cli/clan_cli/machines/update.py b/pkgs/clan-cli/clan_cli/machines/update.py index 5f1096732..abba56b43 100644 --- a/pkgs/clan-cli/clan_cli/machines/update.py +++ b/pkgs/clan-cli/clan_cli/machines/update.py @@ -171,7 +171,7 @@ def deploy_machine(machine: Machine) -> None: if build_host: become_root = False - nix_options += ["--target-host", build_host.target] + nix_options += ["--target-host", target_host.target] if target_host.user != "root": nix_options += ["--use-remote-sudo"] From 28227e8b0aa23c342f54711b666d581cdfeacd86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Tue, 6 May 2025 09:52:25 +0200 Subject: [PATCH 2/2] fix build_host set if it doesn't exist --- pkgs/clan-cli/clan_cli/machines/machines.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkgs/clan-cli/clan_cli/machines/machines.py b/pkgs/clan-cli/clan_cli/machines/machines.py index cc370b46b..6118beb5a 100644 --- a/pkgs/clan-cli/clan_cli/machines/machines.py +++ b/pkgs/clan-cli/clan_cli/machines/machines.py @@ -165,8 +165,7 @@ class Machine: """ build_host = self.override_build_host or self.deployment.get("buildHost") if build_host is None: - with self.target_host() as target_host: - yield target_host + yield None return # enable ssh agent forwarding to allow the build host to access the target host yield parse_deployment_address(