Enviado em 22/06/2016 - 11:12h
Tenho um script que grava chave pública nos servidores que eu uso. Nas versões anteriores do ubuntu 16.04 eu conseguia normalmente. Não sei se está relacionado ao sublime ou ao próprio Ubuntu. Mas hoje não consigo mais. Meu script é:
#!/bin/bashMe retorna o erro:
# Caso não tenha a chave , use o comando: 'ssh-keygen -t rsa' para gerar a mesma.
chave="/home/douglas/.ssh/id_rsa.pub"
usuario="admin"
host="192.168.1.10"
porta="22"
ssh-copy-id -i $chave -p $porta $usuario"@"$host
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/home/douglas/.ssh/id_rsa.pub"O grande lance é que se eu rodar via terminal ele funciona. Como posso resolver?
/usr/bin/ssh-copy-id: INFO: attempting to log in with the new key(s), to filter out any that are already installed
/usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed -- if you are prompted now it is to install the new keys
ssh_askpass: exec(/usr/bin/ssh-askpass): No such file or directory
Permission denied, please try again.
ssh_askpass: exec(/usr/bin/ssh-askpass): No such file or directory
Permission denied, please try again.
ssh_askpass: exec(/usr/bin/ssh-askpass): No such file or directory
Permission denied (publickey,password).