Using an SSH keyfile with Fabric

后端 未结 8 1481
Happy的楠姐
Happy的楠姐 2020-11-28 18:42

How do you configure fabric to connect to remote hosts using SSH keyfiles (for example, Amazon EC2 instances)?

8条回答
  •  Happy的楠姐
    2020-11-28 19:29

    I had to do this today, my .py file was as simple as possible, like the one posted in the answer of @YuvalAdam but still I kept getting prompted for a password...

    Looking at the paramiko (the library used by fabric for ssh) log, I found the line:

    Incompatible ssh peer (no acceptable kex algorithm)

    I updated paramiko with:

    sudo pip install paramiko --upgrade
    

    And now it's working.

提交回复
热议问题