rubygems - Loading the correct gem version error LoadError: cannot load such file -- capistrano/rails -


i trying run capistrano update: cap production deploy

but error: cap aborted! loaderror: cannot load such file -- capistrano/rails /home/deploy/apps/my-web-app/releases/20151214160634/capfile:7:inrequire' /home/deploy/apps/my-web-app/releases/20151214160634/capfile:7:in <top (required)>'

here --trace

$cap production deploy --trace cap aborted! loaderror: cannot load such file -- capistrano/rails /home/deploy/apps/my-web-app/releases/20151214160634/capfile:7:in `require' /home/deploy/apps/my-web-app/releases/20151214160634/capfile:7:in `<top (required)>' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/rake_module.rb:28:in `load' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/rake_module.rb:28:in `load_rakefile' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:689:in `raw_load_rakefile' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:94:in `block in load_rakefile' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:176:in `standard_exception_handling' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:93:in `load_rakefile' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:77:in `block in run' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:176:in `standard_exception_handling' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/rake-10.4.2/lib/rake/application.rb:75:in `run' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/capistrano-3.4.0/lib/capistrano/application.rb:15:in `run' /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/gems/capistrano-3.4.0/bin/cap:3:in `<top (required)>' /home/deploy/.rvm/gems/ruby-2.1.7/bin/cap:23:in `load' /home/deploy/.rvm/gems/ruby-2.1.7/bin/cap:23:in `<main>' /home/deploy/.rvm/gems/ruby-2.1.7/bin/ruby_executable_hooks:15:in `eval' /home/deploy/.rvm/gems/ruby-2.1.7/bin/ruby_executable_hooks:15:in `<main>' 

i believe there issue version of capistrano, uninstalled , tried '2.15' version gives same error.

capistrano defined in gemfile this:

... group :development     gem 'capistrano',         require: false     gem 'capistrano-rvm',     require: false     gem 'capistrano-rails',   require: false     gem 'capistrano-bundler', require: false     gem 'capistrano3-puma',   require: false ... 

edit 1

bundle exec cap production deploy 

gives:

/home/deploy/.rvm/gems/ruby-2.1.7/gems/bundler-1.10.6/lib/bundler/rubygems_integration.rb:292:in `block in replace_gem': capistrano not part of bundle. add gemfile. (gem::loaderror) /home/deploy/apps/my-web-app/shared/bundle/ruby/2.1.0/bin/cap:22:in `<main>' 

edit 2

i moved capistrano lines in gemfile outside of group , ran rvmsudo bundle install.

now bundle exec cap production deploy gives:

bundle exec cap production deploy --trace ** invoke production (first_time) ** execute production ** invoke load:defaults (first_time) ** execute load:defaults cap aborted! nameerror: undefined local variable or method `config' main:object config/deploy/production.rb:35:in `<top (required)>' ... 

use bundle exec cap production deploy ensure gems declared in gemfile being used.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -