我有Windows 7 64位。我用官方安装程序安装了ruby200-x64。我可以用Capistrano成功部署一次,但现在这种错误一直出现:
[deploy:update_code] exception while rolling back: Capistrano::ConnectionError, connection failed for: user@77.77.77.77 (TypeError: no implicit conversion of nil into String)
远程服务器正在运行CentOS并且配置正常,因为我可以毫无问题地从Xubuntu和Mac OS部署它。
部署文件如下所示:
set :application, "application_name"
set :repository, "git@bitbucket.org:username/application_name.git"
set :scm, :git
set :use_sudo, false
set :deploy_to, "/var/www/application_name/"
set :deploy_via, :remote_cache
set :copy_exclude, [".git", ".DS_Store", ".gitignore", ".gitmodules"]
server "user@77.77.77.77", :app
namespace :application do
task :symlink, :roles => :app do
run "if [ -d #{shared_path}/uploads ]; then ln -nfs #{shared_path}/uploads #{release_path}/wp-content/uploads; fi"
end
task :chmod_wp, :roles => :app do
run "chmod -R 755 #{release_path}/.*"
run "find #{release_path}/ -type f -exec chmod 644 {} \\;"
end
end
after "deploy:create_symlink", "application:symlink", "application:chmod_wp"
也许有人对Windows的部署有什么问题?