简体   繁体   English

使用capistrano部署时出现以下错误

[英]getting following error while deploying using capistrano

I did cap deploy, I'm getting following error, 我做了上限部署,出现以下错误,

* executing "cd /home/deployer/apps/nthat1/releases/20130911190337 && bundle install --gemfile /home/deployer/apps/nthat1/releases/20130911190337/Gemfile --path /home/deployer/apps/nthat1/shared/bundle --deployment --quiet --without development test"
  servers: ["192.241.225.72"]
  [192.241.225.72] executing command
** [out :: 192.241.225.72] /home/deployer/.rvm/gems/ruby-1.9.3-p448/gems/psych-1.3.4/lib/psych.rb:96: warning: already initialized constant VERSION
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] /home/deployer/.rvm/gems/ruby-1.9.3-p448/gems/psych-1.3.4/lib/psych.rb:99: warning: already initialized constant LIBYAML_VERSION
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] /home/deployer/.rvm/rubies/ruby-1.9.3-p448/bin/ruby extconf.rb
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] Gem files will remain installed in /home/deployer/apps/nthat1/shared/bundle/ruby/1.9.1/gems/libv8-3.16.14.3 for inspection.
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] Results logged to  /home/deployer/apps/nthat1/shared/bundle/ruby/1.9.1/gems/libv8- 3.16.14.3/ext/libv8/gem_make.out
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] An error occurred while installing libv8 (3.16.14.3), and Bundler cannot
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] continue.
** [out :: 192.241.225.72] 
** [out :: 192.241.225.72] Make sure that `gem install libv8 -v '3.16.14.3'` succeeds before bundling.
** [out :: 192.241.225.72] 
command finished in 174014ms
*** [deploy:update_code] rolling back
* executing "rm -rf /home/deployer/apps/nthat1/releases/20130911190337; true"

I logged into the server, and I did gem install libv8 -v '3.16.14.3' 我登录到服务器,并做了gem install libv8 -v'3.16.14.3'

Building native extensions.  This could take a while...
Successfully installed libv8-3.16.14.3
1 gem installed
Installing ri documentation for libv8-3.16.14.3...
Installing RDoc documentation for libv8-3.16.14.3...

Again I did cap deploy I am getting the same error as stated above. 再次,我做了上限部署,却遇到了与上述相同的错误。

In your deployment you are using a Ruby built with RVM. 在部署中,您使用的是使用RVM构建的Ruby。 When you log into the box to manually install libv8, make sure you are using the same RVM based Ruby that you are using during deployment. 登录框以手动安装libv8时,请确保使用与部署期间使用的相同的基于RVM的Ruby。 Try this after logging in manually: 手动登录后请尝试以下操作:

$ rvm use ruby-1.9.3-p448
$ gem install libv8 -v '3.16.14.3'

Make sure that your ruby is coming from rvm: 确保您的红宝石来自rvm:

$ which ruby
/home/deployer/.rvm/rubies/ruby-1.9.3-p448/bin/ruby

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM