Buildbot
Pages 15
Clone this wiki locally
The OpenSlide Buildbot instance performs nightly builds and test suite runs.
Setting up a buildslave
-
Ensure the system is using a UTF-8 locale.
-
Install build and test suite dependencies, Git, a C compiler, Make, Autoconf, Automake, Libtool, pkg-config, and DejaVu Sans.
-
For each Python major version (2 or 3) which is supported by OpenSlide Python: install Python, Python development headers, setuptools, and Pillow or PIL.
-
Install
stunneland configure it:setuid = stunnel setgid = stunnel pid = /var/lib/stunnel/stunnel.pid [openslide_buildbot] client = yes CAfile = /etc/stunnel/ca.crt cert = /etc/stunnel/stunnel.crt key = /etc/stunnel/stunnel.key verify = 2 options = NO_SSLv2 options = NO_SSLv3 ; Only with stunnel < 4.37 sslVersion = TLSv1 accept = 127.0.0.1:1999 connect = buildbot.openslide.org:2000 -
pip install buildbot-slave -
Create a
buildbotuser account. As thebuildbotuser:buildslave create-slave buildslave 127.0.0.1:1999 <buildslave-name> <buildslave-password> -
Edit
~buildslave/buildslave/info/* -
Add a crontab for
buildslave:PATH=/usr/local/bin:/usr/bin:/bin @reboot buildslave start ~/buildslave
Additional setup for EC2 instances
-
Install Boto ≥ 2.5.0 and Requests ≥ 1.0
-
Ensure the VM will resize its root filesystem on boot. On Linux,
cloud-initwill do this. -
Bundle an AMI using
openslide-automation/scripts/create-amis.py.
Notes for Windows EC2 instances
-
Install
unzip. -
The Buildbot user needs
SeCreateSymbolicLinkPrivilege. Because of access token filtering, this implies that the user must not be an administrator. -
Use
cygrunsrvto install services forstunnelandbuildbot:
cygrunsrv -I stunnel -p /usr/bin/stunnel -a /home/stunnel/stunnel/stunnel.conf -u stunnel
cygrunsrv -I buildbot -p /usr/bin/buildslave
-a "start --nodaemon /home/buildbot/buildslave/" -u buildbot -y stunnel
-e PATH=/usr/local/bin:/usr/bin:/bin:/cygdrive/c/Windows/system32:/cygdrive/c/Windows
`-e PATH=` prevents `cygrunsrv` from adding `/bin` to the beginning of the search path, which breaks CMake.
- Before creating a new AMI, ensure that `Ec2DynamicBootVolumeSize` is set to `Enabled` in `C:\Program Files\Amazon\Ec2ConfigService\Settings\config.xml`.