Capistrano rails deploy fail -


when i'm trying deploy capistrano error

/home/username/.rvm/gems/ruby-2.0.0-p0@dvr/gems/capistrano-2.15.5/lib/capistrano/recipes/deploy/assets.rb:28:in `parse_manifest': undefined method `to_a' #<string:0x9fa62d0> (nomethoderror) 

moreover, in output have multiple instances of this:

** [out :: *ip_here*] shell=/bin/bash ** [out :: *ip_here*] ssh_client=*ip_here* 53366 22 ** [out :: *ip_here*] user=root ** [out :: *ip_here*] mail=/var/mail/root ** [out :: *ip_here*] path=/usr/local/rvm/gems/ruby-2.0.0-p247/bin:/usr/local/rvm/gems/ruby-2.0.0-p247@global/bin:/usr/local/rvm/rubies/ruby-2.0.0-p247/bin:/home/rails/.rvm/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games ** [out :: *ip_here*] pwd=/root ** [out :: *ip_here*] lang=en_us.utf-8 ** [out :: *ip_here*] shlvl=1 ** [out :: *ip_here*] home=/root ** [out :: *ip_here*] language=en_us:en ** [out :: *ip_here*] logname=root ** [out :: *ip_here*] ssh_connection=*ip_here* 53366 *ip_here* 22 ** [out :: *ip_here*] _=/usr/bin/env ** [out :: *ip_here*] ruby_version=ruby-2.0.0-p247 ** [out :: *ip_here*] gem_home=/usr/local/rvm/gems/ruby-2.0.0-p247:/usr/local/rvm/gems/ruby-2.0.0-p247@global ** [out :: *ip_here*] bundle_path=/usr/local/rvm/gems/ruby-2.0.0-p247 

what found out output comes capture function, defined in gem (path_to_cap_gem/configuration/actions/inspect.rb):

def capture(command, options={})         output = ""         invoke_command(command, options.merge(:once => true, :eof => !command.include?(sudo))) |ch, stream, data|           case stream             when :out output << data             when :err warn "[err :: #{ch[:server]}] #{data}"             end           end         output end 

and function parse_manifest tries parse output of capture method instead of wants.

what's totally strange path string /usr/games @ end.

part of gemfile:

gem 'capistrano' gem 'rvm-capistrano' 

capfile:

load 'deploy' # uncomment if using rails' asset pipeline load 'deploy/assets' load 'config/deploy' # remove line skip loading of default tasks 

deploy.rb:

require 'bundler/capistrano' require 'rvm/capistrano' $:.unshift(file.expand_path('./lib', env['rvm_path'])) set :application, 'dvr_rails'   set :rvm_ruby, "ruby-2.0.0-p247" set :rvm_ruby_string, 'ruby-2.0.0-p247@dvr' set :rvm_gem_home, "/usr/local/rvm/gems/#{fetch(:rvm_ruby)}" set :rvm_ruby_path, "/usr/local/rvm/rubies/#{fetch(:rvm_ruby)}" set :default_environment, {         'ruby_version' => fetch(:rvm_ruby),         'gem_home' => "#{fetch(:rvm_gem_home)}:#{fetch(:rvm_gem_home)}@global",         'bundle_path' => fetch(:rvm_gem_home),         'path' => "#{fetch(:rvm_gem_home)}/bin:#{fetch(:rvm_gem_home)}@global/bin:#{fetch(:rvm_ruby_path)}/bin:/home/rails/.rvm/bin:$path;", }  set :rvm_type, :system  # copy exact line. mean :system here*  set :scm, :none set :repository, '.' set :deploy_via, :copy    server 'ip_here', :app, :web, :db, :primary => true  #if using passenger mod_rails uncomment this: namespace :deploy     task :start ; end    task :stop ; end    task :restart, :roles => :app, :except => { :no_release => true }        run "#{try_sudo} touch #{file.join(current_path,'tmp','restart.txt')}"    end end  set :deploy_to, '/var/sites/dvr_rails'  set :user, 'root' set :use_sudo, 'true' set :password, 'password' 

any ideas?

ruby 2.0.0, rails 4, capistrano 2.15.5. server - ubuntu 12.04, js executable - nodejs.

solved it. still dunno happens there in deep of capture function, editing deploy.rb helped. here working config:

require 'bundler/capistrano' require 'rvm/capistrano' $:.unshift(file.expand_path('./lib', env['rvm_path'])) set :application, 'dvr_rails'  set :rvm_ruby, "ruby-2.0.0-p247" set :rvm_ruby_string, "ruby-2.0.0-p247@dvr" set :rvm_gem_home, "/usr/local/rvm/gems/#{fetch(:rvm_ruby_string)}"  =begin # these sets somehow messed everything.  set :rvm_ruby_path, "/usr/local/rvm/rubies/#{fetch(:rvm_ruby)}" set :default_environment, {         'ruby_version' => fetch(:rvm_ruby),         'gem_home' => "#{fetch(:rvm_gem_home)}:#{fetch(:rvm_gem_home)}@global",         'bundle_path' => fetch(:rvm_gem_home),         'path' => "#{fetch(:rvm_gem_home)}/bin:#{fetch(:rvm_gem_home)}@global/bin:#{fetch(:rvm_ruby_path)}/bin:/home/rails/.rvm/bin;", } =end   #set :rvm_bin_path, "/usr/local/rvm/bin" set :rvm_type, :system  # copy exact line. mean :system here*  set :scm, :none set :repository, '.' set :deploy_via, :copy  set :rails_env, 'production'   server 'ip_here', :app, :web, :db, :primary => true   #if using passenger mod_rails uncomment this: namespace :deploy     task :start ; end    task :stop ; end    task :restart, :roles => :app, :except => { :no_release => true }        run "#{try_sudo} touch #{file.join(current_path,'tmp','restart.txt')}"    end end  set :deploy_to, '/var/sites/dvr_rails'  set :user, 'root' #set :use_sudo, 'true' #loggin root, no sudo required set :password, 'password' 

Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

css - Firefox for ubuntu renders wrong colors -