This commit is contained in:
Michael Stanclift 2020-06-01 10:45:52 -05:00
parent 58e0b87001
commit 67de66aa23

View File

@ -932,7 +932,7 @@ function config_generate {
if hash ssh-copy-id 2>/dev/null if hash ssh-copy-id 2>/dev/null
then then
ssh-copy-id -f -i $HOME/${SSH_PKIF}.pub ${REMOTE_USER}@${REMOTE_HOST} ssh-copy-id -f -i $HOME/${SSH_PKIF}.pub ${REMOTE_USER}@${REMOTE_HOST}
elseif hash dropbearkey 2>/dev/null elif hash dropbearkey 2>/dev/null
then then
dropbearkey -t ecdsa -f $HOME/${SSH_PKIF} | grep "^ecdsa" > $HOME/${SSH_PKIF}.pub dropbearkey -t ecdsa -f $HOME/${SSH_PKIF} | grep "^ecdsa" > $HOME/${SSH_PKIF}.pub
cat $HOME/${SSH_PKIF}.pub | dbclient ${REMOTE_USER}@${REMOTE_HOST} 'cat - >> .ssh/authorized_keys' cat $HOME/${SSH_PKIF}.pub | dbclient ${REMOTE_USER}@${REMOTE_HOST} 'cat - >> .ssh/authorized_keys'