![]() ![]() id_Ĥ -rwxr-xr-x 1 sammy sammy 222 Jul 12 20:21 known_hostsĪnd result for ls -ld ~/.ssh ls -ld ~/.sshĭrw-rw-rw- 2 sammy sammy 4096 Jul 13 21:25 /home/sammy/. The default keys are named idrsa.pub (public key) and idrsa (private key). As far as ansible is concerned, it has executed the command echo with all of the rest of the line as arguments to echo. Result from sudo ls -lsa ~/.ssh sudo ls -lsa ~/.sshĤ drw-rw-rw- 2 sammy sammy 4096 Jul 13 21:25. The ansible command module does not pass commands through a shell.This means you cant use shell operators such as the pipe, and that is why you are seeing the pipe symbol in the output. If you have further questions please stop by IRC or the mailing list: IRC: ansible on mailing list. usr/bin/ssh-copy-id: INFO: 1 key(s) remain to be installed - if you are prompted now it is to install the new password: ssh-copy-id is not maintained by Ansible. I've also tried sshing from my computer, but the authentication was broken and I tried to fix it but it fails ssh-copy-id INFO: attempting to log in with the new key(s), to filter out any that are already installed I want to do this with Ansible on serverA automatically. This can be done manually by calling ssh-copy-id userserverB on serverA. rwxr-xr-x 1 sammy sammy 397 Jul 12 20:25 /home/sammy/.ssh/id_rsa.pub I want serverA to be able to access serverB by copying the sshpubkey of serverA to serverB. Heres an example where I copy my ssh key to via the jump host : ssh-copy-id -o password: Number of key (s) added: 1. ssh: Permission sudo ls -l ~/.ssh/id_rsa.pub By using the ProxyJump option you can use ssh-copy-id to copy your key to a host via jump host. (to install the contents of '/home/sammy/.pub' anyway, look at the -f cd. pub path or wrong settings for ssh cat ~/.ssh/id_rsa.pubĬat: /home/sammy/.ssh/id_rsa.pub: Permission ssh-copy-id ERROR: failed to open ID file '/home/sammy/.pub': No such file It will call sshpass(FYI, maybe OSX dont ship with sshpass by default). I'm trying to setup ssh-copy-id on ubuntu I need a second opinion on this, is this a missing. For ssh password prompt, try to use ansible/ansible-playbook -k/-ask-pass. ![]()
0 Comments
Leave a Reply. |