[英]Bundler, ExecJS, Mac OS X and Debian
I'm developing Rails on Mac OS X 10.8 and trying to use Capistrano to deploy to Debian Squeeze . 我正在Mac OS X 10.8上开发Rails,并尝试使用Capistrano部署到Debian Squeeze 。
Deploying gives me this error: 部署给我这个错误:
Could not find libv8-3.3.10.4 in any of the sources
It seems to be that I have bundle package
-da Mac OS X binary gem: 似乎我有bundle package
-da Mac OS X二进制gem:
Updating files in vendor/cache
...
* libv8-3.3.10.4-x86_64-darwin-12.gem
The Gemfile
has: Gemfile
具有:
gem 'therubyracer'
I want to use binary gems because Squeeze does not provide Node.js from package manager and I would like to keep source compiling out of production server. 我想使用二进制gem,因为Squeeze没有从包管理器中提供Node.js,并且我希望将源代码编译排除在生产服务器之外。
Is there any way to tell Bundler to package both Linux and Darwin binaries? 有没有办法告诉捆扎机打包Linux和达尔文的二进制文件?
BTW, how does therubyracer
accomplish this when it too uses Bundler ? 顺便说一句,当therubyracer
也使用Bundler时,如何做到这一点?
在您的Debian libv8
上安装libv8
。
One solution was to skip bundle package
which would download all packages from source, but his made deploy too slow for my taste (probably b/c for some reason it still didn't download binary gem and compiled libv8 afresh each time). 一种解决方案是跳过bundle package
,该软件包将从源代码下载所有软件包,但他的部署对我而言太慢了(可能出于某些原因,b / c仍然没有每次都下载二进制gem和重新编译libv8)。
So I ended up installing Node.js
from source to the Debian box and document that as a prerequirement for the project. 因此,我最终将Node.js
从源代码安装到Debian盒中,并将其记录为该项目的先决条件。 Then I commented out this part of Gemfile
: 然后我注释掉了Gemfile
这一部分:
group :assets do
...
# gem 'therubyracer'
...
end
Now I can again bundle package
the whole lot and deploy fast. 现在,我可以再次bundle package
并快速部署。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.