Multiple reviewboard instances possible?

97 views
Skip to first unread message

mary

unread,
Aug 7, 2008, 4:17:36 PM8/7/08
to reviewboard
Hi,

I want to host multiple reviewboard sites from the same server (each
to have their own database, authentication routines, and apache
virtual server.)

Is this possible?

It appears not. I tried to setup another site-packages site for my
second reviewboard site without success. When I tried to run manage.py
script it says it MUST be run from directory called "reviewboard" (so
I can't have "reviewboard-2" for example.)

Any insight? I want to avoid having to setup another machine.

Thanks!

Christian Hammond

unread,
Aug 8, 2008, 1:30:51 AM8/8/08
to revie...@googlegroups.com
It's definitely possible. I run three on the review-board.org server.

I want to have a better story for this later, but the method I use is to have a copy of reviewboard in each vhost, rather than using one in site-packages. You then set up mod_python or whatever for each instance. It serves me quite well.

There's a few things that make using the site-packages instance for multiple servers not work completely well. For example, Review Board assumes uploaded files go in MEDIA_ROOT/uploaded, but this doesn't work for a single site-packages instance, so until we fix that there will be problems in this case. Multiple checkouts of Review Board don't have this problem.

Christian

--
Christian Hammond - chi...@chipx86.com
VMware, Inc.

mary

unread,
Aug 18, 2008, 3:14:19 PM8/18/08
to reviewboard
Thanks, that's great! I'll give it a try.

The one thing I'm not clear on is how to specify a different
reviewboard settings_local.py for each vhost, but after reading DJANGO
docs more closely I think this can be achieved by setting mod_python
PythonPath to first have /var/www/<mysite> and then keep the unique
settings_local.py there (instead of at site-packages/reviewboard.)

On Aug 7, 10:30 pm, "Christian Hammond" <chip...@chipx86.com> wrote:
> It's definitely possible. I run three on the review-board.org server.
>
> I want to have a better story for this later, but the method I use is to
> have a copy of reviewboard in each vhost, rather than using one in
> site-packages. You then set up mod_python or whatever for each instance. It
> serves me quite well.
>
> There's a few things that make using the site-packages instance for multiple
> servers not work completely well. For example, Review Board assumes uploaded
> files go in MEDIA_ROOT/uploaded, but this doesn't work for a single
> site-packages instance, so until we fix that there will be problems in this
> case. Multiple checkouts of Review Board don't have this problem.
>
> Christian
>
> --
> Christian Hammond - chip...@chipx86.com
> VMware, Inc.
>
>
>
> On Thu, Aug 7, 2008 at 1:17 PM, mary <ciaom...@gmail.com> wrote:
>
> > Hi,
>
> > I want to host multiple reviewboard sites from the same server (each
> > to have their own database, authentication routines, and apache
> > virtual server.)
>
> > Is this possible?
>
> > It appears not. I tried to setup another site-packages site for my
> > second reviewboard site without success. When I tried to run manage.py
> > script it says it MUST be run from directory called "reviewboard" (so
> > I can't have "reviewboard-2" for example.)
>
> > Any insight? I want to avoid having to setup another machine.
>
> > Thanks!- Hide quoted text -
>
> - Show quoted text -

Chris Lamb

unread,
Aug 18, 2008, 4:11:48 PM8/18/08
to revie...@googlegroups.com
Christian Hammond wrote:

> > > I want to host multiple reviewboard sites from the same server

[..]


> > I want to have a better story for this later, but the method I use is to
> > have a copy of reviewboard in each vhost, rather than using one in
> > site-packages.

This isn't necessary. You can install Review Board in a central location,
copy the default settings_local.py to a fresh directory and then symlink the
manage.py to the same directory.

(However, you will need the patch mentioned below)

> > There's a few things that make using the site-packages instance for
> > multiple servers not work completely well. For example, Review Board
> > assumes uploaded files go in MEDIA_ROOT/uploaded, but this doesn't work
> > for a single site-packages instance

I've submitted a patch for review that does this. Christian, could you take
a quick look at it?


Regards,

--
Chris Lamb, UK ch...@chris-lamb.co.uk
GPG: 0x634F9A20

signature.asc

mary

unread,
Aug 18, 2008, 4:37:10 PM8/18/08
to reviewboard
Thanks, I just wanted to report I got this working, it was
surprisingly easy!

Here are some further details if anyone is interested...
I used the central site-packages/reviewboard directory and just moved
the unique settings_local.py file to /var/www/<sites> directories and
ensured that the cooresponding directory was in the PythonPath for
each vhost entry (i'm using apache). (Of note, I also had to remove
the settings_local.pyc file from central location for my local
settings file to take affect.) For both virtual hosts I just symlink
the VS directory to the central site-packages/reviewboard/htdocs
location. That was it!
>  signature.asc
> < 1KViewDownload

mary

unread,
Aug 18, 2008, 5:22:57 PM8/18/08
to reviewboard
I take that back, the vhosts and settings_local.py files at first
appeared to be working, but both site 1 and site 2 are hitting the
same database! This is despite having different databases configured
in the settings file in addition to unique SITE_IDs. I do not
understand django/reviewboard enough at this point to understand whats
going on here.
> > < 1KViewDownload- Hide quoted text -

Christian Hammond

unread,
Aug 18, 2008, 6:37:02 PM8/18/08
to revie...@googlegroups.com
Make sure you have a PythonInterpreter line in your apache config (assuming you're using mod_python). The value can be anything, but I recommend something like reviewboard-sitename.

For example:

    PythonInterpreter reviewboard-foobar

Christian

--
Christian Hammond - chi...@chipx86.com
VMware, Inc.
Reply all
Reply to author
Forward
0 new messages