From 016b3e846dbf2a55b19e4d5d99509431481b3fc5 Mon Sep 17 00:00:00 2001 From: Johannes Kirschbauer Date: Thu, 15 Aug 2024 15:00:51 +0200 Subject: [PATCH] Machine update: fix upload sources from machine flake, instead of current directory --- pkgs/clan-cli/clan_cli/machines/update.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pkgs/clan-cli/clan_cli/machines/update.py b/pkgs/clan-cli/clan_cli/machines/update.py index d0845aa6d..3d76900a1 100644 --- a/pkgs/clan-cli/clan_cli/machines/update.py +++ b/pkgs/clan-cli/clan_cli/machines/update.py @@ -97,8 +97,10 @@ def deploy_machine(machines: MachineGroup) -> None: generate_vars([machine], None, False) upload_secrets(machine) - path = upload_sources(".", target) - + path = upload_sources( + str(machine.flake.path) if machine.flake.is_local() else machine.flake.url, + target, + ) if host.host_key_check != HostKeyCheck.STRICT: ssh_arg += " -o StrictHostKeyChecking=no" if host.host_key_check == HostKeyCheck.NONE: