【发布时间】:2012-03-19 13:53:54
【问题描述】:
我正在尝试在 Dreamhost 上设置我的 Rails 应用程序,并且我正处于尝试设置 Capistrano 的阶段。
我在部署的服务器上设置了一个 git 服务器。我已经设置了 SSH 密钥(我认为)——至少我可以 SSH 没有问题。
'cap deploy:setup' 和 'cap deploy:check' 都运行没有错误。
但是当我尝试运行 'cap deploy:migrations' 时,我得到以下信息:
* executing `deploy:migrations'
* executing `deploy:update_code'
updating the cached checkout on all servers
executing locally: "git ls-remote user@server.dreamhost.com:git/project.git master"
command finished in 1065ms
* executing "if [ -d /home/user/domain.com/shared/cached-copy ]; then cd /home/user/domain.com/shared/cached-copy && git fetch origin && git fetch --tags origin && git reset --hard 406475489f2934554f5b80cf17e44576ba7ee02f && git clean -d -x -f; else git clone user@domain.dreamhost.com:git/project.git /home/user/domain.com/shared/cached-copy && cd /home/user/domain.com/shared/cached-copy && git checkout -b deploy 406475489f2934554f5b80cf17e44576ba7ee02f; fi"
servers: ["server.dreamhost.com"]
[server.dreamhost.com] executing command
** [server.dreamhost.com :: out] Cloning into /home/user/domain.com/shared/cached-copy...
这就是问题所在:
** [server.dreamhost.com :: err] Host key verification failed.
** [server.dreamhost.com :: err] fatal: The remote end hung up unexpectedly
command finished in 157ms
failed: "sh -c 'if [ -d /home/user/domain.com/shared/cached-copy ]; then cd /home/user/domain.com/shared/cached-copy && git fetch origin && git fetch --tags origin && git reset --hard 406475489f2934554f5b80cf17e44576ba7ee02f && git clean -d -x -f; else git clone user@server.dreamhost.com:git/project.git /home/user/domain.com/shared/cached-copy && cd /home/user/domain.com/shared
我已经删除了我的密钥并创建了新密钥(同样,通过 SSH 连接到服务器可以正常工作)但无济于事。这可能是我的一个非常基本的误解,但我无法弄清楚。
【问题讨论】:
标签: ruby-on-rails capistrano dreamhost ssh-keys