[Buildbot-devel] accessing slave homedir in master?
Martin Geisler
mg at daimi.au.dk
Thu Sep 18 21:26:01 UTC 2008
Jimmy John <jimmyj_in at yahoo.com> writes:
> Is there any way to run a command and pass as argument the slave's
> home dir...
>
> eg. if i want to run a command to create a dir at the slave home e.g.
>
> f.addStep(shell.ShellCommand(name="creating new dir",
> haltOnFailure=True,
> command=["mkdir", "-p",
> "$HOME/xxx_buildbot/%s" %
> dir_builder_name],
> workdir="build/splunk/current",
> description=["creating new dir"],
> descriptionDone=["created new dir"],
> timeout=120))
>
>
> does not give me what i want....it creates a dir called '$HOME'...any
> way i can get the environment variables expanded before they get
> used....
>
> argv: ['mkdir', '-p',
> '$HOME/xxx_buildbot/Slave2_-_SunOS_-_perforce_nightly_tests']
Try specifying the command as a string instead. That will force buildbot
to pass the string to the shell and let it parse it as if you had
executed "sh -c 'mkdir -p $HOME/...'". The shell will then interpret the
$HOME for you (provided it is set in the environment).
--
Martin Geisler
VIFF (Virtual Ideal Functionality Framework) brings easy and efficient
SMPC (Secure Multi-Party Computation) to Python. See: http://viff.dk/.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: <http://buildbot.net/pipermail/devel/attachments/20080918/45b9673a/attachment.bin>
More information about the devel
mailing list