Mongrel can be started with a prefix e.g. mongrel_rails start -p 3000 --prefix /foobar So that all of the app''s URLs are prefixed, e.g. http://localhost:3000/foobar http://localhost:3000/foobar/posts http://localhost:3000/foobar/posts/1 The problem is that if you hit just the root ( http://localhost:3000/ ) then mongrel responds with "NOT FOUND". I tried adding an index.html to RAILS_ROOT/public that redirects to / foobar, but this results in an infinite loop. Does anyone know how to get requests to the root to redirect to the prefix? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I think you are missing a piece of the puzzle, Apache and mod_proxy... You would never run multiple app roots unless you had multiple apps and or a php app on / and a rails app on /app1... If you want multiple apps running on your dev env just start them with -p 3001 -p 3002 ... ? much easier... but I guess that depends on what you are trying to do ... --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On Jan 28, 11:50 am, Freddy Andersen <fre...-RCI/mp9mI1I6GGFevw1D/A@public.gmane.org> wrote:> I think you are missing a piece of the puzzle, Apache and > mod_proxy... >Yes, this is running behind Apache. We have a Java app that runs at http://java.ourdomain.com/foo We have Apache proxy forwarding http://java.ourdomain.com/bar to http://rails.ourdomain.com/bar ...so that ajax calls aren''t cross-domain to the java app. The issue with redirecting the root requests to the prefixed URL is more a matter of convenience, just so someone doesn''t see "NOT FOUND" if they happen to hit the root URL. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---