aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Eilertsen <haraldei@anduin.net>2017-12-26 14:06:27 +0100
committerHarald Eilertsen <haraldei@anduin.net>2017-12-26 14:06:27 +0100
commit2612e429af202633bc1472a46157d8803bf7037c (patch)
tree626c2a8225a4000f489fe8500083a619e1321392
parentad7591bbac5b65bdaebba795300a37fe04295cc1 (diff)
downloadhmnoweb-2612e429af202633bc1472a46157d8803bf7037c.tar.gz
hmnoweb-2612e429af202633bc1472a46157d8803bf7037c.tar.bz2
hmnoweb-2612e429af202633bc1472a46157d8803bf7037c.zip
Mount Refinery under suburl if specified in environment.
This is to make sure all generated url's within the application uses the correct base URL.
-rw-r--r--config/routes.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/config/routes.rb b/config/routes.rb
index 2eb025f..0c10b0d 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -5,7 +5,7 @@ BetaWebApp::Application.routes.draw do
# If you would like to change where this extension is mounted, simply change the :at option to something different.
#
# We ask that you don't use the :as option here, as Refinery relies on it being the default of "refinery"
- mount Refinery::Core::Engine, :at => '/'
+ mount Refinery::Core::Engine, at: ENV['RAILS_RELATIVE_URL_ROOT'] || '/'
# The priority is based upon order of creation:
# first created -> highest priority.