mirror of
https://github.com/nix-community/nixos-anywhere.git
synced 2024-08-16 20:00:36 +03:00
print error message to stderr if ssh-keyscan fails
This commit is contained in:
parent
c5fc538880
commit
d4fbe4c173
@ -335,7 +335,7 @@ for path in "${!disk_encryption_keys[@]}"; do
|
||||
done
|
||||
|
||||
pubkey=$(ssh-keyscan -p "$ssh_port" -t ed25519 "$ssh_host" 2>/dev/null || {
|
||||
echo "ERROR: failed to retrieve host public key for ${ssh_connection}"
|
||||
echo "ERROR: failed to retrieve host public key for ${ssh_connection}" >&2
|
||||
exit 1
|
||||
})
|
||||
pubkey=$(echo "$pubkey" | sed -e 's/^[^ ]* //' | base64 -w0)
|
||||
|
Loading…
Reference in New Issue
Block a user