From 622e00afbb8cb718640675b2605241eca8613f1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sat, 5 Aug 2023 10:37:25 +0200 Subject: [PATCH 1/2] also pass ssh_args to rsync --- src/nixos-anywhere.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/nixos-anywhere.sh b/src/nixos-anywhere.sh index e1369f59..172107ef 100755 --- a/src/nixos-anywhere.sh +++ b/src/nixos-anywhere.sh @@ -429,7 +429,10 @@ if [[ -n ${extra_files-} ]]; then extra_files="$extra_files/" fi step Copying extra files - rsync -rlpv -FF -e "ssh -i \"$ssh_key_dir\"/nixos-anywhere -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no" "$extra_files" "${ssh_connection}:/mnt/" + rsync -rlpv -FF \ + -e "ssh -i \"$ssh_key_dir\"/nixos-anywhere -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no ${ssh_args[*]}" \ + "$extra_files" \ + "${ssh_connection}:/mnt/" ssh_ "chmod 755 /mnt" # rsync also changes permissions of /mnt fi From 3197bcf152bbb2d49ced9def814d1d9920b92a52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Sat, 5 Aug 2023 10:38:56 +0200 Subject: [PATCH 2/2] drop unused : --- src/nixos-anywhere.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/src/nixos-anywhere.sh b/src/nixos-anywhere.sh index 172107ef..34a771ab 100755 --- a/src/nixos-anywhere.sh +++ b/src/nixos-anywhere.sh @@ -242,7 +242,6 @@ elif [[ -n ${disko_script-} ]] && [[ -n ${nixos_system-} ]]; then if [[ ! -e ${disko_script} ]] || [[ ! -e ${nixos_system} ]]; then abort "${disko_script} and ${nixos_system} must be existing store-paths" fi - : else abort "flake must be set" fi