Skip to content

Commit

Permalink
added ssh key file check
Browse files Browse the repository at this point in the history
  • Loading branch information
root committed Oct 4, 2018
1 parent d7578d2 commit 14cc547
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions link-with-server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ get_host_fingerprint(){
ssh-keygen -l -f $file 2> /dev/null | grep ECDSA | awk '{print $2}'
}

[[ -f $SSH_KEY_FILE ]] || die "No ssh key file found."

SSH="$SSH -q -oStrictHostKeyChecking=no -oUserKnownHostsFile=/dev/null \
-oPreferredAuthentications=publickey $SSH_USER@$SSH_HOST -p $SSH_PORT -i $SSH_KEY_FILE"

Expand Down

0 comments on commit 14cc547

Please sign in to comment.