简体   繁体   中英

Ansible SSH Key Setup

I'm dipping my toes into Ansible and I'm having trouble configuring SSH keys.

I currently have two Ubuntu 14.04 VMs running and present in the Ansible hosts file.

I also have an extra VM which is being used for Ansible management.

I have created an SSH key on the management machine and 'ssh-copy-id' them to both of the Ubuntu 14.04 VMs.

Based on watching videos and following tutorials of Ansible configuration, I should now be able to run 'ansible instancegroupname -m ping' sequentially on both of the machines without having to enter a password.

However when running that command on the management VM, I am prompted to enter the SSH passphrase for the management VM itself, something I have not seen in the tutorial videos. It just seems to work for them?

Thanks guys.

通过将ssh-key添加到ssh-agent可以解决此问题。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM