On Nov 20, 2005, at 6:28 AM, Giovanni Giorgi wrote:
> Hi,
> I''d like to spread to other rubyOnRails developers this simple
> configuration I found userful for setting up ruby.
>
> A easy way to set up ruby is to proxying the request versus WEBrick.
> This is not the preferred way for a true production site but it
> works fine.
>
>
> To to so, I have changed the "config/routes.rb" to prepend the /
> rails/ path to every url:
> #[GG] Changed to support proxing
> map.connect ''rails/:controller/:action/:id''
>
> Then I set up on apache a proxy rule like this:
>
> <IfModule mod_proxy.c>
> ProxyPass /rails/ http://yoda.local:3000/rails/
ProxyPassReverse /rails/
http://yoda.local:3000/rails/> ProxyRequests Off
> </IfModule>
If you add the above rails will never interject the port number onto
the url.>
> It works fine and result also in a centralized way of distributing
> the load.
> For instance, I have to machine on my site:
>
> + a true old web server (very slow, it can serve only static pages
> and so on)
> + a brand new mac mini, powered by ruby on rails
>
> So the slow machine forward the request to the mac mini, and I get
> a very FAST way of setting up a development
> env. on the internet!
>
> For more magic tips see
> http://manuals.rubyonrails.com/read/chapter/65
>
> --
>
> [ [ [ JJ ] ] ] | Temi cio'' che conosci, non
> | cio'' che non conosci
> http://www.siforge.org |
>
> _______________________________________________
> Rails mailing list
> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
-Ezra Zygmuntowicz
WebMaster
Yakima Herald-Republic Newspaper
ezra-gdxLOakOTQ9oetBuM9ipNAC/G2K4zDHf@public.gmane.org
509-577-7732