[Buildbot-devel] slave os.environ['HOME']

Ryan Raasch ryan.raasch at gmail.com
Thu Jun 25 19:02:49 UTC 2009

The way of building out of tree is not possible with buildbot, it seems. 
A configure script is run

when in /home/build/usr/src-build one runs 
/home/build/usr/src/configure. This absolute path stuff is not possible. 
Unless a home directory is not used (/opt, /var, ... ) (now that i think 
about it).

Or is there another way?

Dustin J. Mitchell wrote:
> On Thu, Jun 25, 2009 at 9:14 AM, Ryan Raasch<ryan.raasch at gmail.com> wrote:
>> To do this, though, i need to find the HOME directory on the slave. I am
>> not that great with python (like it a lot, but moreless newbie).
> Maybe you could back up a bit and think about why you need this?  I
> don't really understand your description.  Do you just need to find a
> common place from which to access the source code, without copying it
> into each build dir?
> The problem is that, when the master.cfg is parsed, the slaves aren't
> connected yet.  So there's absolutely no way to get a value from the
> slaves into a local variable.
> You're right that SVN doesn't accept properties, because it is
> intended to run as the first step.
> If my guess is correct, then you don't want to use the SVN step in
> your builders (because you don't want to do a checkout for each
> builder).  Instead, you'll need to find some way to atomically update
> your common repository (or a shell command that uses some kind of
> locking to prevent simultaneous updates?) on each buildslave.  If you
> can, just make that common repository appear in the same place on
> every slave.  Otherwise, since you're using a shell script to update
> the repo, just use $HOME in that shell script.  Then each buildfactory
> starts with this "update-the-common-repo" step, probably followed by
> an 'rm -rf foo; mkdir foo' to clean out the build directory, followed
> by the regular steps for your build.
> Dustin

More information about the devel mailing list