我正在尝试在我的生产服务器上部署我的 bitbucket 存储库,但无法。当我从我的 Git bash 执行 push pull 时,一切正常,但 capistrano 未能达到同样的效果。
set :application, "my_app"
set :user, "username"
set :repository, "ssh://git@bitbucket.org/accountname/repository.git"
role :web, "www.domain.com"
set :deploy_to, "/home/domaincom/domain.com"
set :use_sudo, false
set :scm, :git
set :branch, 'master'
set :deploy_via, :copy
set :copy_cache, true
set :copy_exclude, %w(.git)
task :create_symlinks, :roles => :web do
run "rm #{current_release}/public/.htaccess"
run "ln -s #{current_release}/shared/.htaccess #{current_release}/public/.htaccess"
run "ln -s /home/domaincom/libraries/Zend #{current_release}/library/Zend"
end
after "deploy:finalize_update", :create_symlinks
我得到的错误是在部署时
:No such file or directory -git ls-remote ssh://git@bitbucket.org/accountname/repository.git master (Error::ENOENT)
请帮助我,我在过去的 4 天里一直坚持这一点。也尝试添加部署密钥。但没有任何效果
编辑:另外请不要在我的生产服务器上安装 Git 和 Capistrano。我在 Windows 机器上使用 capistrano