OK, I've been chasing this for hours and I just can't figure it out. I have a Ruby on Rails application that I've deployed to my hosting provider DreamHost. I've created a new environment called "stage" and created a stage.rb file in the /config/environment folder and put the following line into my environment.rb
# Be sure to restart your server when you modify this file
# Specifies gem version of Rails to use when vendor/rails is not present
RAILS_GEM_VERSION = '2.3.5' unless defined? RAILS_GEM_VERSION
ENV["RAILS_ENV"] ||= "stage"
# Bootstrap the Rails environment, frameworks, and default configuration
require File.join(File.dirname(__FILE__), 'boot')
Rails::Initializer.run do |config|
I am able to run
RAILS_ENV=stage script/console
and everything runs fine. I can run rake db:migrate and generate my database. I can then drop into the console and act upon my model. I can also see the ActiveRecord activity in stage.log
The problem is when I open a browser and navigate to the URL I get the 500 error of
We're sorry, but something went wrong.
When I try to access the site through a browser I don't see anything written to stage.log.
My apache log file looks like this.
1.1.1.1 - - [19/Jan/2010:06:05:01 -0800] "GET /classes/calendar HTTP/1.1" 500 861 "-" "Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_5_8; en-us) AppleWebKit/531.21.8 (KHTML, like Gecko) Version/4.0.4 Safari/531.21.10"
I've even tried running the application controllers from the console and that works too. I just can't figure out why the page won't serve properly from a browser.
Is there a permission setting that I'm missing. I think on DreamHost the FTP user and the user that the server runs under are the same so I think I have the correct permissions but I'm just not sure.
Any help would be appreciated, Rob