2010-05-31 50 views
2

我試圖部署具有織物Django應用程序,並得到以下 錯誤:面料部署問題

Alexs-MacBook:fabric alex$ fab config:instance=peergw deploy -H <ip> - 
u <username> -p <password> 

[192.168.2.93] run: cat /etc/issue 

Traceback (most recent call last): 

    File "build/bdist.macosx-10.6-universal/egg/fabric/main.py", line 

419, in main 

    File "/Users/alex/Rabota/server/mx30/scripts/fabric/fab/ 

commands.py", line 37, in deploy 

    checkup() 

    File "/Users/alex/Rabota/server/mx30/scripts/fabric/fab/ 

commands.py", line 140, in checkup 

    if not 'Ubuntu' in run('cat /etc/issue'): 

    File "build/bdist.macosx-10.6-universal/egg/fabric/network.py", line 

382, in host_prompting_wrapper 

    File "build/bdist.macosx-10.6-universal/egg/fabric/operations.py", 

line 414, in run 

    File "build/bdist.macosx-10.6-universal/egg/fabric/network.py", line 

65, in __getitem__ 

    File "build/bdist.macosx-10.6-universal/egg/fabric/network.py", line 

140, in connect 

    File "build/bdist.macosx-10.6-universal/egg/paramiko/client.py", 

line 149, in load_system_host_keys 

    File "build/bdist.macosx-10.6-universal/egg/paramiko/hostkeys.py", 

line 154, in load 

    File "build/bdist.macosx-10.6-universal/egg/paramiko/hostkeys.py", 

line 66, in from_line 

    File "build/bdist.macosx-10.6-universal/egg/paramiko/rsakey.py", 

line 61, in __init__ 

paramiko.SSHException: Invalid key 

Alexs-MacBook:fabric alex$ 

我無法通過ssh連接到服務器。什麼是我的問題?

問候,Arshavski亞歷山大。

回答

1

走出去的肢體在這裏,我想說你的SSH密鑰不正確:

paramiko.SSHException: Invalid key

什麼是您的服務器的說,當你嘗試ssh到它,使用的用戶名和密碼,你提供給布?

第二個想法是:當您爲面料提供密碼時,可能表明您的SSH主機密鑰已更改和/或尚未添加到~/.ssh/known_hosts

1

是的,我想說你連接的機器上的主機密鑰已經改變了。 (或者你從一臺從未通過「xxx是未知主機的機器連接,是否要將其添加到已知主機列表中?」對話框)。

如果您不關心man-in -the中間人攻擊或自己已經改變了密鑰的前幾天某處添加以下行你env.variables:

env.disable_known_hosts = True 

應該照顧它!