[Buildbot-devel] Running two version of buildbot on same machine
Brian Warner
warner-buildbot at lothar.com
Sun May 13 00:14:24 UTC 2007
Gregory Golberg <grisha at snaplogic.org> writes:
>> numbers of 0.7.3 (for example). Is there a way, perhaps modifying the
>> python paths, to make it use the local versions of the buildbot code so
>> that I can test it without having to blow away our earlier installation?
Yup, it's actually pretty easy: you can put the directory of the version you
want to run at the front of your PYTHONPATH. The /usr/bin/buildbot tool
always uses the first version of the 'buildbot' python package that appears
on PYTHONPATH.
So, for example, if you unpacked version 0.7.5 into ~/buildbot-0.7.5 , you
could do:
cd ~/test-new-version
PYTHONPATH=~/buildbot-0.7.5 buildbot create-master ...
PYTHONPATH=~/buildbot-0.7.5 buildbot start ...
In this case, the 'buildbot' script itself is coming from your installed
version, but all that script does is to import the rest of buildbot (using
the usual search rules of PYTHONPATH) and hand off control to it. So it
really doesn't matter which copy of the script you use; it's been unchanged
for years.
Remember to keep tha PYTHONPATH setting when you stop/start/restart the
buildbot, though, because it isn't sticky, and if you forget it you'll
probably end up with a master or slave that's running the installed version
instead of the one you intended.
cheers,
-Brian
More information about the devel
mailing list