Project

General

Profile

Multiple URI instances of redmine on one apache server

Added by Kevin Judd over 13 years ago

I want to have two instances of redmine running on the same apache server with different mysql databases behind them. These instances of redmine will have different projects, different users and authentication, different everything really.

I have an out-of-the-box Ubuntu 10.04 installation of apache2, redmine, redmine-mysql

configured so that redmine is available as

http://localhost/redmine

and /etc/redmine/default/database.yml pointing to a mysql database called redmine

It would be sufficent for my purposes to create another mysql database called say 'anotherredmine'
available from

http://localhost/anotherredmine

This
http://www.redmine.org/wiki/redmine/HowTo_Install_Redmine_using_Debian_package
hints that this ought to be possible. And this thread too
http://www.redmine.org/boards/1/topics/16647
but it doesn't seem to be what I want.

I imagine what I need to do is something like the following, but I need expert advice.

1) Create and populate a new mysql database anotherredmine (I assume there is some script to do this?)

2) Modify my apache2 conf to now have

<Directory /var/www/redmine>
RailsBaseURI /redmine
PassengerResolveSymlinksInDocumentRoot on
</Directory>
<Directory /var/www/anotherredmine>
RailsBaseURI /anotherredmine
PassengerResolveSymlinksInDocumentRoot on
</Directory>

3) create or link /var/www/anotherredmine to something like /usr/share/redmine/public or a copy of it.

4) Do some more configuration ...

What I don't see is how to create the new redmine database, and configure things so that /anotherredmine runs from this second database.

Kevin


Replies (3)

RE: Multiple URI instances of redmine on one apache server - Added by Felix Schäfer over 13 years ago

The debian package installs a heavily "debian-ified" version of redmine, and as I don't use it I can't say much about it. Have you read the supplied README.Debian, I think it contains some instructions regarding multiple instances too. You could also contact the maintainer of the debian package or at least ask him to have a look at this forum thread, he should be the one most apt to answer your question ;-)

RE: Multiple URI instances of redmine on one apache server - Added by Kevin Judd over 13 years ago

Ah, thanks, good pointer, that appears to tell me exactly what I require.

Kevin

RE: Multiple URI instances of redmine on one apache server - Added by Eugene NGONTANG almost 11 years ago

Hi all!

I have installed two redmine instances on debian squeeze, and made the following symlinks :

ln -s /var/lib/redmine/firstinstance /var/www/firstinstance
ln -s /var/lib/redmine/secondinstance /var/www/secondinstance

But when trying to launch the redmine interface i have the error page attached here.

And if I try to generate store session or to make a rake db:migrate, I have the following error:

root@vps21646:~# rake -f /usr/share/redmine/Rakefile generate_session_store
(in /root)
rake aborted!
No such file or directory - /etc/redmine/default/session.yml

(See full trace by running task with --trace)
root@vps21646:~#
root@vps21646:~# rake -f /usr/share/redmine/Rakefile generate_session_store --trace
(in /root)
** Invoke generate_session_store (first_time)
** Execute generate_session_store
rake aborted!
No such file or directory - /etc/redmine/default/session.yml
/usr/share/redmine/lib/tasks/initializers.rake:9:in `initialize'
/usr/share/redmine/lib/tasks/initializers.rake:9:in `open'
/usr/share/redmine/lib/tasks/initializers.rake:9
/usr/lib/ruby/1.8/rake.rb:636:in `call'
/usr/lib/ruby/1.8/rake.rb:636:in `execute'
/usr/lib/ruby/1.8/rake.rb:631:in `each'
/usr/lib/ruby/1.8/rake.rb:631:in `execute'
/usr/lib/ruby/1.8/rake.rb:597:in `invoke_with_call_chain'
/usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
/usr/lib/ruby/1.8/rake.rb:590:in `invoke_with_call_chain'
/usr/lib/ruby/1.8/rake.rb:583:in `invoke'
/usr/lib/ruby/1.8/rake.rb:2051:in `invoke_task'
/usr/lib/ruby/1.8/rake.rb:2029:in `top_level'
/usr/lib/ruby/1.8/rake.rb:2029:in `each'
/usr/lib/ruby/1.8/rake.rb:2029:in `top_level'
/usr/lib/ruby/1.8/rake.rb:2068:in `standard_exception_handling'
/usr/lib/ruby/1.8/rake.rb:2023:in `top_level'
/usr/lib/ruby/1.8/rake.rb:2001:in `run'
/usr/lib/ruby/1.8/rake.rb:2068:in `standard_exception_handling'
/usr/lib/ruby/1.8/rake.rb:1998:in `run'
/usr/bin/rake:28
root@vps21646:~#

, like if rake is looking for session file in my default instance, which does not exist, because i two different redmine instance without name "default", in my "/etc/remine/" dir.

Thanks a lot for givin a help.

    (1-3/3)