[Rails] Ruby site structure on Apache

Pat Maddox
2006-02-24T19:35:56Z

You need to make the document root RAILS_ROOT/public, not RAILS_ROOT.
There''s absolutely no reason your rails code needs to be available
over HTTP, and in fact is a security risk.  Consider that anyone can
go to config/database.yml and see your connection info.

If you can''t explicitly set the docroot to RAILS_ROOT/public, then you
should put your app in a non HTTP-accessible folder and use a symlink.

Pat



On 2/24/06, mark sheran <markshen2004@gmail.com>
wrote:
> I use a hosting company,it use appache for RoR
>
> I test a ''hello word'' code here
>
> http://www.smtservers.com/demo/
>
> I can see the working code here
>
> http://www.smtservers.com/demo/public/say/hello
>
> My question is how to short the url like
>
> http://www.smtservers.com/demo/say/hello.I do not like public always in
> URL
>
> Thanks for help
>
> Mark
>
> --
> Posted via http://www.ruby-forum.com/.
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>