# Different path to public document root in Development mode

**URL:** <https://www.ruby-forum.com/t/different-path-to-public-document-root-in-development-mode/142448>\
**Category:** Rails\
**Created:** [July 8, 2008, 2:49am UTC](https://www.ruby-forum.com/t/different-path-to-public-document-root-in-development-mode/142448 "2008-07-08T02:49:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![nwiger](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/dbc845/32.png) [@nwiger](https://www.ruby-forum.com/u/nwiger)\
**Post date:** [July 8, 2008, 2:49am UTC](https://www.ruby-forum.com/t/different-path-to-public-document-root-in-development-mode/142448/1 "2008-07-08T02:49:32Z")

</div>

I know how to do this for actual deployment, but is there a way to  
change the Rails “document root” used from its default of RAILS\_ROOT/  
public _in development mode_?

I want to do something like this:

config.document\_root = “/shared/global/images”

Since I have several different applications using the same image sets.

We can’t use svn:externals or other tricks due to some complexities  
I’ve omitted, so I’m hoping there’s a way to configure this in  
environment.rb

Thanks,  
Nate

---

<div class="post-metadata">

**Author:** ![nwiger](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/n/dbc845/32.png) [@nwiger](https://www.ruby-forum.com/u/nwiger)\
**Post date:** [July 8, 2008, 10:54pm UTC](https://www.ruby-forum.com/t/different-path-to-public-document-root-in-development-mode/142448/2 "2008-07-08T22:54:14Z")

</div>

Is it enough to change the asset host (for serving stylesheets,  
javascripts  
etc)?

Copy the line:  
config.action\_controller.asset\_host = ‘[http://whatever/](http://whatever/)’  
from production.rb to development.rb

Hope this helps.  
Phil

2008/7/8 Nate W. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid):
