我执行了一个命令“ cap production deploy ”。但控制台显示如下:
I, [2014-04-07T11:08:40.266235 #12701] INFO -- net.ssh.connection.session[..fdb4b635a]: channel_extended_data: 1 1 128b
DEBUG [e73f4d85] /usr/local/rvm/scripts/cli: line 808: 13251 Killed "$rvm_scripts_path/set" "$rvm_action" "${rvm_ruby_args[@]}"
D, [2014-04-07T11:08:40.269274 #12701] DEBUG -- tcpsocket[..fdb38dce4]: read 140 bytes
D, [2014-04-07T11:08:40.269566 #12701] DEBUG -- tcpsocket[..fdb38dce4]: received packet nr 18 type 96 len 12
I, [2014-04-07T11:08:40.269687 #12701] INFO -- net.ssh.connection.session[..fdb4b635a]: channel_eof: 1
D, [2014-04-07T11:08:40.269874 #12701] DEBUG -- tcpsocket[..fdb38dce4]: received packet nr 19 type 98 len 44
I, [2014-04-07T11:08:40.270011 #12701] INFO -- net.ssh.connection.session[..fdb4b635a]: channel_request: 1 exit-status false
cap aborted!
bundle stdout: Nothing written
bundle stderr: Nothing written
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/command.rb:94:in `exit_status='
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:138:in `block (4 levels) in _execute'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/channel.rb:551:in `call'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/channel.rb:551:in `do_request'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:561:in `channel_request'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:465:in `dispatch_incoming_packets'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:221:in `preprocess'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh- 2.7.0/lib/net/ssh/connection/session.rb:205:in `process'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `block in loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/channel.rb:269:in `wait'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:160:in `block (2 levels) in _execute'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/channel.rb:514:in `call'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/channel.rb:514:in `do_open_confirmation'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:545:in `channel_open_confirmation'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:465:in `dispatch_incoming_packets'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:221:in `preprocess'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:205:in `process'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `block in loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/net-ssh-2.7.0/lib/net/ssh/connection/session.rb:169:in `loop'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:162:in `block in _execute'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:119:in `tap'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:119:in `_execute'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:66:in `execute'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/capistrano-bundler-1.1.1/lib/capistrano/tasks/bundler.cap:20:in `block (4 levels) in <top (required)>'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/abstract.rb:81:in `within'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/capistrano-bundler-1.1.1/lib/capistrano/tasks/bundler.cap:19:in `block (3 levels) in <top (required)>'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:54:in `instance_exec'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/backends/netssh.rb:54:in `run'
/home/ckj/.rvm/gems/ruby-1.9.3-p327/gems/sshkit-1.2.0/lib/sshkit/runners/parallel.rb:12:in `block (2 levels) in execute'
Tasks: TOP => deploy:updated => bundler:install
这是我的 deploy.rb :
set :application, 'dorm-hub'
set :scm, :git
set :repo_url, "git@github.com:XXX/XXXX.git"
set :stages, [:production, :staging]
set :default_stage, :production
这是我的 production.rb :
set :deploy_to, "/root/www/xxx"
set :stage, :production
set :rvm_type, :system
set :rvm_ruby_version, "2.0.0-p353"
set :default_env, { rvm_bin_path: "/usr/local/rvm/bin"}
set :ssh_options, {
verbose: :debug
}
role :app, %w{root@xxx.com}
role :web, %w{root@xxx.com}
role :db, %w{root@xxx.com}
server 'root@xxx.com', user: 'root', roles: %w{web app}
我尝试了很多东西,但它不起作用。 请有人告诉我如何解决这个问题?