Redmine + Apache2 + Passenger + Sub URI on Ubuntu
Added by John Bruckler over 13 years ago
Version information and VHosts file is below.
Specifically what I want to do is be able to access redmine as a sub uri (I've had a look at HowTo_Install_Redmine_in_a_sub-URI and based on that, I added Redmine::Utils::relative_url_root = "/redmine"
as the very last line of environment.rb. It seems like I've done things right - I can, in fact go to http://medic/redmine and I get the login page. Unfortunately, when I go to http://medic I also get the Redmine login page. I have a RailsBaseURI directive in my vhosts file, it's presence/absence don't seem to make a difference.
One other thing to note - after I don't do anything with the site (say, overnight) when I got back to visit it again, I get a 404 error when attempting to go to http://medic/redmine - going to http://medic displays the login page without any stylesheets or anything loaded.
I assume I have a misconfiguration somewhere, but as I know nothing about Ruby, Rails or Passenger, I'm at a loss as to where. Any assistance will be greatly appreciated.
TLDR: I only want to be able to access redmine at http://medic/redmine, but I can access it at http://medic too (and my main site content is not displayed)
Ruby: ruby 1.8.7 (2010-08-16 patchlevel 302) [x86_64-linux]
Rails: 2.3.5
OS: Ubuntu Server 11.04
Server version: Apache/2.2.17 (Ubuntu)
Output of gem list
*** LOCAL GEMS *** i18n (0.4.2) mysql (2.8.1) rack (1.1.0)
My VirtualHost file
<VirtualHost *:80> ServerName medic DocumentRoot /opt/sites/medic <Directory /opt/sites/medic> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all </Directory> #---- Redmine Goodness ---- PassengerAppRoot /opt/sites/medic/redmine RailsBaseURI /redmine Alias /redmine /opt/sites/medic/redmine/public ErrorLog ${APACHE_LOG_DIR}/medic/error.log # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. LogLevel warn CustomLog ${APACHE_LOG_DIR}/medic/access.log combined </VirtualHost>
Replies (1)
RE: Redmine + Apache2 + Passenger + Sub URI on Ubuntu - Added by John Bruckler over 13 years ago
I suspect this isn't getting attention because of the title - it's not a matter of getting redmine to work on a sub URI, it's about getting redmine to not hijack my main site.