[Buildbot-devel] add IPMI hooks on the master side when the source code changes
clepple at gmail.com
Sat Jul 14 13:24:15 UTC 2012
On Jul 14, 2012, at 7:44 AM, Brice Goglin wrote:
> Is it possible to have custom hooks run on the *master* side whenever a
> GIT or SVN change occurs? We want to power down most of our slave
> machines during the summer holidays, but we would like to have the
> buildbot master power up the slave machines (with IPMI) when there's a
> new build to run. Is this possible?
It's possible: http://buildbot.net/buildbot/docs/latest/manual/cfg-buildsteps.html#running-commands-on-the-master
The trick is that if you shut down a buildslave, the slave will be marked as offline, so the master-side command won't run (a slave has to be online during the entire time that the build runs).
One way around this, if you have a relatively simple configuration, is to add a buildslave that runs on the master machine (so that it is always online), and set up a build with two steps: first, run the IPMI command, then trigger your actual build on the slave machines.
Similarly, shutting down a slave can be tricky. You don't want to run "poweroff" right at the end of the build, unless you are sure that you will never have two builds queued up at once, and that the poweroff command isn't quick enough to kill the slave connection before the build ends.
There is a "graceful shutdown" mechanism that I haven't had a chance to experiment with: http://buildbot.net/buildbot/docs/latest/manual/installation.html#other-buildslave-configuration
clepple at gmail
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the devel