Quick project: Visual indicator for a bamboo build server

Keep a log of a project build here. Be sure to include pictures and as much documentation as possible.

Quick project: Visual indicator for a bamboo build server

Postby annath » December 25th, 2013, 6:30 pm

At my office, we use Bamboo as a continual integration server, to run builds and unit tests for us in the background and keep better track of what build is in the field.

It's configured to run a build any time we push code to the remote git repo (via polling the git server). When I'm working, I don't necessarily want to stop what I'm doing to go make sure a build passed or failed, so I wanted some kind of visual way of knowing that my build was running, and when it finished.

I decided RGB LEDs would be the way to go for a simple visual indicator. I wrote a script in Ruby to poll Bamboo's REST API to get the latest build and some simple details about it. The first step was just printing all of this to the console.

Next, I wrote a simple program for an arduino (which should work on just about any Arduino with three PWM pins, so practically all of them) that takes a command via serial to set its display "mode." Then I added a reference to the serialport Ruby gem so that I could write simple commands to the Arduino.

The display modes I added to start with are:

  • Pulsing blue indicates a build is running
  • Solid red for a failed build
  • Solid green for a successful build
The hardware is very simple. It's just an RGB LED with three 10k resistors.

(The mega was the only thing I had on hand to work with)
Image

Image

In the future I want to add one of Adafruit's NeoPixel Rings with some slightly more complex animations.

Here is the full imgur album (with higher res images) and the source code. Also, here is a video of the indicator changing: http://youtu.be/QiAmd63fzj0

This was a pretty quick project that I think has lot's of potential for expansion. It would be pretty simple to modify it for other build servers (Jenkins, Travis CI, etc).
annath
 
Posts: 26
Joined: December 15th, 2013, 3:50 pm

Return to Project Logs

Who is online

Users browsing this forum: No registered users and 1 guest