public this repo is viewable by everyone
Description: Phusion Passenger (mod_rails)
Homepage: http://www.modrails.com/
Clone URL: git://github.com/FooBarWidget/passenger.git
Click here to lend your support to: passenger and make a donation at www.pledgie.com !
Set RAILS_ROOT to '.' during Ruby on Rails framework preloading. Fixes 
issue #29.
Hongli Lai (Phusion) (author)
9 days ago
commit  53301de464b323d364723854d3a8d293ab8327d6
tree    23e53e1e40d0fea9ecd6312dca292b3e7f2f5cb8
parent  3f5fb12ba8240018c6210a42d2550d21a3cd6497
...
241
242
243
 
244
245
246
...
266
267
268
 
269
270
271
...
241
242
243
244
245
246
247
...
267
268
269
270
271
272
273
0
@@ -241,6 +241,7 @@ protected
0
 
0
 private
0
   def preload_rails
0
+    Object.const_set(:RAILS_ROOT, ".")
0
     if @version
0
       gem 'rails', "=#{@version}"
0
       require 'initializer'
0
@@ -266,6 +267,7 @@ private
0
       require 'action_web_service'
0
     end
0
     require 'active_support/whiny_nil'
0
+    Object.send(:remove_const, :RAILS_ROOT)
0
   end
0
 
0
   def handle_spawn_application(app_root, lower_privilege, lowest_user)

Comments

    No one has commented yet.