乘客 (mod-rails) 找不到 libopenssl-ruby

fli*_*tux 4 ruby 11.10 rails nginx

尝试在 Ubuntu 11.10 上使用Phusion Passenger构建nginx服务器(为新版本欢呼吧!)。运行“passenger-install-nginx-module”输出以下错误:

* OpenSSL support for Ruby... not found
Run Code Online (Sandbox Code Playgroud)

使用以下建议来修复它:

* To install OpenSSL support for Ruby:
  Please run apt-get install libopenssl-ruby as root.
Run Code Online (Sandbox Code Playgroud)

运行“sudo apt-get install libopenssl-ruby”会产生以下输出:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Note, selecting 'libruby' instead of 'libopenssl-ruby'
libruby is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Run Code Online (Sandbox Code Playgroud)

一些研究表明,libruby 是一个虚拟包,它提供 libopenssl-ruby 作为包的一部分。但是,passenger-install-nginx-module 脚本仍然找不到它,并不断抛出相同的错误。请帮帮我!我在这个问题上有点不知所措,而通常有效的 google-the-error-code 方法今天让我失望了。

小智 7

你需要切换到你的 rubyext/openssl/目录,然后运行

ruby extconf.rb 
make
make install
Run Code Online (Sandbox Code Playgroud)

然后再试passenger-install-nginx-module一次