我遵循heroku博客上给出的有关部署Rails应用程序的所有准则。我还成功推送了我的应用程序,并在我的帐户中创建了一个应用程序。但是,当我尝试运行我的网站时,出现以下错误:
App crashed
This application is temporarily offline.
If you're the administrator of this app, please check your heroku logs for the
backtrace.
我试图检查日志,这就是我得到的
C:\Users\raw\Desktop\html\rohit>heroku logs
Missing the Rails 2.3.8 gem. Please `gem install -v=2.3.8 rails`, update your RAILS_GEM_
VERSION setting in config/environment.rb for the Rails version you do have installed, or
comment out RAILS_GEM_VERSION to use the latest version installed.
==> dyno-3674485.log (crash) <==
Missing the Rails 2.3.8 gem. Please `gem install -v=2.3.8 rails`, update your RAILS_GEM_
VERSION setting in config/environment.rb for the Rails version you do have installed, or
comment out RAILS_GEM_VERSION to use the latest version installed.
-----> Rails can't find the expected version.
Check to ensure you have specified the correct version of Rails in your
Gemfile or .gems. See http://docs.heroku.com/gems for details.
You may also be affected by a gem dependency issue with rack.
See http://docs.heroku.com/gem-dependency for details.
Examine the backtrace above this message to debug.
我已经在我的Rails_App目录中创建了一个
.gems
文件:rails -v '2.3.8'
pg
rack -v '1.1.0'
haml -v '3.0.13'
formtastic -v '0.9.8'
authlogic -v '2.1.5'
subdomain-fu -v '0.5.4'
compass -v '0.10.2'
compass-colors -v '0.3.1'
paperclip -v '2.3.3'
activemerchant -v '1.9.0'
icalendar
我该怎么做才能使它正常工作?
最佳答案
Rails 2.3.8与机架1.2.1不兼容。您无法定义.gems,就像您在定义中遇到“机架的 gem 依赖问题”一样。
尝试使用rake -v = 1.1.0依赖于ActionPack 2.3.8(http://rubygems.org/gems/actionpack/versions/2.3.8)
关于ruby-on-rails - 将Rails应用程序部署到Heroku时出现App Crashed错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4436692/