rails bluehost错误Ruby(Rack)应用程序无法启动 [英] rails bluehost error Ruby (Rack) application could not be started

查看:292
本文介绍了rails bluehost错误Ruby(Rack)应用程序无法启动的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经通过许多问题部署一个简单的rails应用程序,并且认为当我看到rails欢迎屏幕时,一切都很好...然后当我选择了关于你的应用程序环境的默认链接时,我看到很多错误rails页面。错误在下面,并且当我去特定的URL时也出现。

I've worked through many issues deploying a simple rails app and thought all was good when i saw the rails welcome screen... then I saw lots of errors when I selected the "about your applications environment" link of the default rails page. The errors are below and also appear when I go to specific URLs.

我认为问题是我的〜/ .bashrc文件显式地调用

I THINK the issue is that my ~/.bashrc file is explicitly calling for

    export GEM_PATH=$GEM_HOME:/usr/lib64/ruby/gems/1.8

当错误参考gems / 1.9.3

when the errors reference gems/1.9.3

我只是不知道这是否是问题或如何改变这些东西,使所有人都同意女巫对方。用1.9.3替换1.8没有做伎俩(虽然我无法弄清楚我可能需要运行什么捆绑或更新命令来完成这项工作)。

I'm just not sure if this is the issue or how to change this stuff to make it all agree witch each other. replacing 1.8 with 1.9.3 didn't do the trick (although I couldn't figure out what bundle or update commands i may have to run to make that work).

我会感谢你可以提供的任何方向或建议...我新的蓝色导轨部署,我确定我在这里缺少一些东西..

I'd appreciate any direction or advice you can offer... I"m new with bluehost rails deployments and i'm sure i'm missing something here..


错误消息:
在任何源中找不到i18n-0.6.1(Bundler :: GemNotFound )
异常类:
PhusionPassenger :: UnknownError

Error message: Could not find i18n-0.6.1 in any of the sources (Bundler::GemNotFound) Exception class: PhusionPassenger::UnknownError

后跟:

Backtrace:
#   File    Line    Location
0   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/spec_set.rb  88  in `block in materialize'
1   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/spec_set.rb  82  in `map!'
2   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/spec_set.rb  82  in `materialize'
3   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/definition.rb    90  in `specs'
4   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/definition.rb    135     in `specs_for'
5   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/definition.rb    124     in `requested_specs'
6   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/environment.rb   23  in `requested_specs'
7   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler/runtime.rb   11  in `setup'
8   /usr/lib64/ruby/gems/1.9.3/gems/bundler-1.0.21/lib/bundler.rb   110     in `setup'
9   /etc/httpd/modules/passenger/lib/phusion_passenger/utils.rb     326     in `prepare_app_process'
10  /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb  156     in `block in initialize_server'
11  /etc/httpd/modules/passenger/lib/phusion_passenger/utils.rb     572     in `report_app_init_status'
12  /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb  154     in `initialize_server'
13  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb   204     in `start_synchronously'
14  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb   180     in `start'
15  /etc/httpd/modules/passenger/lib/phusion_passenger/rack/application_spawner.rb  129     in `start'
16  /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb     253     in `block (2 levels) in spawn_rack_application'
17  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb    132     in `lookup_or_add'
18  /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb     246     in `block in spawn_rack_application'
19  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb    82  in `block in synchronize'
20      prelude>    10:in `synchronize'
21  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server_collection.rb    79  in `synchronize'
22  /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb     244     in `spawn_rack_application'
23  /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb     137     in `spawn_application'
24  /etc/httpd/modules/passenger/lib/phusion_passenger/spawn_manager.rb     275     in `handle_spawn_application'
25  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb   357     in `server_main_loop'
26  /etc/httpd/modules/passenger/lib/phusion_passenger/abstract_server.rb   206     in `start_synchronously'
27  /etc/httpd/modules/passenger/helper-scripts/passenger-spawn-server  99  in `'


推荐答案

看到我的答案这里

请注意,安装RVM时,会看到它会自动修改.bash_profile以使用正确的路径,在 / home /< user> /。rvm /...中,不在 / user / lib64 中。

Note that when installing RVM, you'll see it automatically modify .bash_profile to use correct paths, which will be in /home/<user>/.rvm/..., not in /user/lib64.

编辑:忘记我的答案。即使可能使用当前安装的Ruby 1.8来运行Rails 3.x(请参阅此Stackoverflow问题),您将无法使用Bluehost共享托管运行Ruby 1.9.x。您的唯一选择(现在)是VPS主机。

Nevermind my answer. Even though it might be possible to get Rails 3.x running with the currently installed Ruby 1.8 (see this Stackoverflow question), you won't be able to run Ruby 1.9.x using Bluehost Shared Hosting. Your only choice (for now) is VPS Hosting.

原因是Passenger Phusion与/ usr / lib中安装的Ruby版本相关联, t无root权限更改。即使您可以使用RVM安装任何版本的Ruby,您也不会让Passenger与之对话,因此您的rails项目不会使用其宝石。

The reason is that Passenger Phusion is tied to the version of Ruby installed in /usr/lib, which you can't change without root access. Even though you can install any version of Ruby with RVM, you won't get Passenger to talk to it and therefore your rails project won't use its gems.

这篇关于rails bluehost错误Ruby(Rack)应用程序无法启动的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆