【问题标题】:Capistrano and Rails deployment, unable to access bitbucket repo from ubuntu serverCapistrano 和 Rails 部署,无法从 ubuntu 服务器访问 bitbucket 存储库
【发布时间】:2016-05-24 09:54:29
【问题描述】:

我有一个可以成功部署 Rails 项目的 Ubuntu 服务器。我创建了一个新项目,并希望将其部署到同一台服务器。但是我在访问 Capistrano 部署期间存储代码的 bitbucket 存储库时遇到问题。

DEBUG [60fbbd0f] Command: /usr/bin/env chmod +x /tmp/<project_name>/git-ssh.sh
INFO [60fbbd0f] Finished in 0.098 seconds with exit status 0 (successful).
INFO [b7870f98] Running /usr/bin/env git ls-remote --heads git@bitbucket.org:rmac/<project_name>.git as www-data@88.xxx.xxx.xxx
DEBUG [b7870f98] Command: ( GIT_ASKPASS=/bin/echo GIT_SSH=/tmp/<project_name>/git-ssh.sh /usr/bin/env git ls-remote --heads git@bitbucket.org:rmac/<project_name>.git )
DEBUG [b7870f98]    conq: repository does not exist.
DEBUG [b7870f98]    fatal: Could not read from remote repository.
DEBUG [b7870f98]    
DEBUG [b7870f98]    Please make sure you have the correct access rights
DEBUG [b7870f98]    and the repository exists. 

我试过了

SSHKit::Runner::ExecuteError

和其他答案,但无济于事。我检查了我的服务器进程并且 ssh 代理正在运行。我很难理解看到我的其他项目部署到服务器没有问题。我使用的是同一台机器,相同的部署密钥,相同的 bitbucket 帐户。

有什么想法吗?

谢谢

【问题讨论】:

  • 我注意到了这一点,但鉴于它已有两年历史,我认为它不会提供太多东西。
  • 它还是很有用的。至少,我建议在尝试引导您完成调试之前先尝试一下。
  • 好的,谢谢,现在试一试,然后报告
  • @will_in_wi 是的,它没有告诉我任何新信息。我现在唯一确定的是 ssh kit 正在运行。休息和以前一样。它在这个 ssh:remote:repo_access 上跳闸

标签: ruby-on-rails git ubuntu ssh capistrano3


【解决方案1】:

(在聊天中找到答案)

由于正在使用 ssh-agent,请使用 ssh -A destination_servergit clone 确认 ssh-agent 正在工作。

由于正在部署另一个项目,请确认 Bitbucket 存储库 URL 正确。 (这最终成为了答案)

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-03-08
    • 1970-01-01
    • 2016-04-21
    • 2015-10-29
    相关资源
    最近更新 更多