我一直試圖通過AWS使用Ansible。AWS上的Ansible,無法使用私鑰
我正在使用ppk文件登錄AWS。我想和Ansible一樣使用。
這個ppk文件是從我從AWS獲得的pem文件中提取的。
這是我正在使用的命令。
ansible all -m ping -u ubuntu --private-key /opt/keys/privateKey.ppk
我得到以下
Enter passphrase for key '/opt/keys/privateKey.ppk
172.31.50.XX | FAILED => SSH Error: Permission denied (publickey).
while connecting to 172.31.50.XX:22
It is sometimes useful to re-run the command using -vvvv, which prints SSH debug output to help diagnose the issue.
我沒有創建一個passphase的鍵,以便不知道爲什麼我收到此錯誤
Ansible在封面下使用OpenSSH,因此您需要使用AWS爲您生成的原始Pem文件。 – ydaetskcoR
工作。用pem文件。在主機文件中有ppk文件的引用,我不得不刪除 –