Ruby on rails 3.2 Capistrano部署错误

Ruby on rails 3.2 Capistrano部署错误,ruby-on-rails-3.2,capistrano,Ruby On Rails 3.2,Capistrano,我是ruby应用程序部署的新手 我正在尝试在Capistrano上部署名为“bookshop”的应用程序。 我已经在github上上传了我的应用程序,有以下链接“git@github.com:my_account_name/bookshop.git“ 在执行“cap部署:设置”时,出现以下错误: servers: ["localhost"] connection failed for: localhost (Errno::ECONNREFUSED: Connection refused - co

我是ruby应用程序部署的新手

我正在尝试在Capistrano上部署名为“bookshop”的应用程序。 我已经在github上上传了我的应用程序,有以下链接“git@github.com:my_account_name/bookshop.git“

在执行“cap部署:设置”时,出现以下错误:

servers: ["localhost"]
connection failed for: localhost (Errno::ECONNREFUSED: Connection refused - connect(2))
任何帮助都将不胜感激

我的“deployment.rb”文件:


确保您的计算机中已启用ssh代理。

您的计算机上是否正在运行web服务器和数据库?web服务器是,我正在运行。。。。我如何需要数据库。。。你能告诉我所有的步骤吗网络服务器是的我正在运行。。。。我如何需要数据库。。。你能告诉我所有的步骤吗。。。
set :application, "bookshop"

set :domain,"localhost"
server domain, :web, :app

default_run_options[:pty]= true
set :use_sudo, false

set :aplication,"localhost"

set :scm, :git
set :user, 'bookshop.com'
set :deploy_to, "/home/www/bookshop"
set :repository, "git@github.com:my_account_name/bookshop.git"

role :web, "localhost"                          # Your HTTP #server, Apache/etc
role :app, "localhost"                          # This may be the #same as your `Web` server
role :db,  "localhost", :primary => true # This is where #Rails migrations will run

 namespace :deploy do
   task :start do ; end
   task :stop do ; end
   task :restart, :roles => :app, :except => { :no_release => true } do
     run "#{try_sudo} touch #{File.join(current_path,'tmp','restart.txt')}"
   end
 end