To set the environment, just hard code it in environment.rb where it
says to set it… It says something about “only set this if you can’t
set it from your server.”
I’ve successfully set this up on IIS with virtual directories but I have
to hack routes.rb and environment.rb in order to make it work properly.
It seems to run pretty fast…
Actually, I was able to set the RAILS_ENV variable under the system
variables and it seems to do the trick. Production log is produced and
the production database setting is used.
The one thing to note is that trying to run the console still tries to
use the development settings and the looking at ENV[‘RAILS_ENV’]
shows development.
I do have another problem though. I can’t seem to get my “” route to
work. IIS keeps complaining that it wont display the directory
contents. I think I need to add something to the re-write rules for
it, but not sure what.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.