Skip to content

Commit

Permalink
Add space to SSH command to fix error when using -i option
Browse files Browse the repository at this point in the history
Using the `-i` option to supply a SSH key fails with the error 'Safety check failed - the destination does not appear to be a backup folder or drive (marker file not found).' This seems to be because of a missing space in the SSH parsing code which means that the key address and the SSH address get munged together. This pull request simply adds a space between them.
  • Loading branch information
wragge authored Jan 16, 2024
1 parent 248de06 commit 60853de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rsync_time_machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ def parse_ssh(
ssh_user = ssh["user"] if ssh["user"] else ""
ssh_host = ssh["host"]
auth = f"{ssh_user}@{ssh_host}" if ssh_user else ssh_host
ssh_cmd = f"ssh -p {ssh_port} {'-i ' + id_rsa if id_rsa else ''}{auth}"
ssh_cmd = f"ssh -p {ssh_port} {'-i ' + id_rsa if id_rsa else ''} {auth}"

ssh_src_folder_prefix = f"{auth}:" if ssh_src else ""
ssh_dest_folder_prefix = f"{auth}:" if ssh_dest else ""
Expand Down

0 comments on commit 60853de

Please sign in to comment.