|Bob Mottram bacfbb80ec Option to reboot after build failures||3 weeks ago|
|images||6 months ago|
|man||3 weeks ago|
|LICENSE||6 months ago|
|Makefile||6 months ago|
|PKGBUILD||6 months ago|
|README.md||1 month ago|
|birbci||3 weeks ago|
|birbci_template.html||1 month ago|
This is a minimalistic continuous integration system which will periodically try to build a given set of target projects and report the status.
Install some dependencies. On a Debian based system:
sudo apt-get install git build-essential nginx python-xmpp
Or an an Arch/Parabola based system:
sudo pacman -S git nginx python2 git clone https://github.com/normanr/xmpppy cd xmpppy sudo python2 setup.py install cd ..
Nginx is optional. You could use a different web server, or just view the html file created to display build statuses directly within a browser.
Then install birbci from the repo:
git clone https://code.freedombone.net/bashrc/birbci cd birbci sudo make install
Create a script to build the application which you want to test, such as:
#!/bin/bash set -e set -x make
Rather than just knowing whether the target project compiles you might also want to run any unit tests within the build script and have it return a non-zero value if any tests fail.
So that it's accessible to the build system you may want to save this script into a directory called /etc/birbci
Install a target to be built with:
sudo birbci --repo [your git repo url] --branch master --script /etc/birbci/build.sh -w /var/www/html/index.html --install [build name]
The build name could be similar to the name of the system being tested, but not identical so as to avoid potential clashes. The -w option defines a html file which will contain the results.
The above install could be performed multiple times for different test repos with different build scripts.
Optionally you can also use the --email option to specify an email address which will be notified if a build failure occurs. Whether you use this depends upon if you have an email server locally installed.
If you wish to receive build failure notifications via XMPP then the --xmpp option can be used. For this to work you'll need to have prosody installed and configured.
sudo birbci --repo [your git repo url] --branch master --script /etc/birbci/build.sh -w /var/www/html/index.html --install [build name] --xmpp user@xmppdomain
If you later want to remove a repo from the CI system:
sudo birbci --remove [build name]
To view the results navigate to or open the html file. The result should look something like this, with the colours of the icons indicating success (green), failure (red) or building (gray).
You can also customize the web page if you want it to look different or have your own branding. Copy the birbci_template.html file into your /var/www/html directory and customize it as needed. Don't add anything below the table, but anything above can be changed.
Selecting the build name will show the build log, so that you can view any compile errors or unit test failures.