2011-04-12 87 views
0

试图使用Nginx(在EC2 Linux上)安装Passenger。我使用ec2-user(而不是Root)。 Ruby 1.9.2与RVM。在linux上使用rvm在Nginx上安装乘客的问题

乘客宝石安装正确。

但是当我尝试:

passenger-install-nginx-module 

我得到:

检查所需的软件...

* GNU C++ compiler... not found 
* The 'make' tool... found at /usr/bin/make 
* A download tool like 'wget' or 'curl'... found at /usr/bin/wget 
* Ruby development headers... found 
* OpenSSL support for Ruby... not found 
* RubyGems... found 
* Rake... found at /home/ec2-user/.rvm/wrappers/ruby-1.9.2-p180/rake 
* rack... found 
* Curl development headers with SSL support... not found 
* OpenSSL development headers... not found 
* Zlib development headers... not found 

尽管存在以上。例如,如果I型:

$> gcc 
$> gcc: no input files 

锯某处网上,我可以尝试使用:

rvmsudo passenger-install-nginx-module 

,但我得到了一个问题:

-------------------------------------------- 

Checking for required software... 

* GNU C++ compiler... not found 
* The 'make' tool... found at /usr/bin/make 
* A download tool like 'wget' or 'curl'... found at /usr/bin/wget 
* Ruby development headers... found 
* OpenSSL support for Ruby... not found 
* RubyGems... found 
Unable to locate the RVM path. Your RVM installation is probably too old. Please update it with 'rvm update --head && rvm reload && rvm repair all'. 

任何想法?

+2

试图这样做有消息称是什么? 'rvm update --head && rvm reload && rvm repair all' – 2011-04-12 17:10:24

+0

安装所有找不到的库。乘客在写入失败后如何安装 – fl00r 2011-04-12 17:11:09

+0

@pablob是的。事实上,我刚刚安装了RVM,因此它安装的是最新的 – Tam 2011-04-12 17:31:11

回答

1

在尝试安装Rubies和/或Passenger之前,请确保系统上存在编译器和所有依赖库。通过运行以下命令,可以获取基于Ruby的应用程序的推荐基本依赖项列表。

user$ rvm requirements 

在试图安装解释器之前安装'ruby'列出的所有依赖项? 该列表因操作系统而异。

更多信息,请RVM基础知识文档页面上找到,https://rvm.io/rvm/basics/

〜韦恩

0
Unable to locate the RVM path. 

这可能是不增加的症状:

[[ -s "/usr/local/rvm/scripts/rvm" ]] && source "/usr/local/rvm/scripts/rvm" 

到.bashrc (或简介或其他)。这可能会导致各种奇怪的问题。

0

正在使用ruby​​-1.9.2-p180与rvm。
CD〜/ .rvm/src目录/红宝石1.9.2-P180/EXT/OpenSSL的/
红宝石extconf.rb
使
使安装
乘客安装-gninx模块

4

你有要做到这一点:

rvm remove 1.9.2 
rvm pkg install openssl 
rvm install 1.9.2 --with-openssl-dir=$HOME/.rvm/usr 
+0

现在是:rvm pkg install openssl – ablemike 2012-02-02 23:17:29

0

gcc是错误的可执行文件,乘客正在寻找g ++。与此安装:

sudo yum install gcc-c++ 

和乘客的安装,Nginx的模块应该停止抱怨缺少的gcc