Running Rails App In A Subdirectory

Posted by Weston Ganger

I was having wierd asset issues and other errors when running my Rails app in a sub-directory

Example: mydomain.com/myapp

The main fix is to add relative_url_root to your configuration. You probably only need to define this in production.


# config/environments/production.rb

config.action_controller.relative_url_root = "/myapp"


Related External Links:

Article Topic:Software Development - Rails

Date:May 25, 2015

Recommended Posts