Skip to content

Instantly share code, notes, and snippets.

@hithwen
Created May 21, 2013 21:07
Show Gist options
  • Save hithwen/5623269 to your computer and use it in GitHub Desktop.
Save hithwen/5623269 to your computer and use it in GitHub Desktop.
buildbot running a test server and retrieving output after running client tests
class StopServer(ShellCommand):
def _init_(self):
ShellCommand.__init__(self, command=['pkill', '-f', 'my-server-name'],
workdir='build/python',
description='Stopping test server')
def createSummary(self, log):
buildername = self.getProperty("buildername")
f = '/home/buildbot/slave/%s/build/python/nohup.out' % buildername
output = open(f, "r").read()
self.addCompleteLog('server output', output)
class StartServer(ShellCommand):
def _init_(self):
ShellCommand.__init__(self, command=['./start-test-server.sh'],
workdir='build/python', haltOnFailure=True,
description='Starting test server')
#!/bin/bash
export PYTHONPATH="${PYTHONPATH}:${PWD}"
nohup my-serever-launcher.py >nohup.out 2>&1 &
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment