Looking to get Continuous Integration running for your project in short order? I recently took a look at CI in a Box, which is a
cloud based solution that provides Hudson, as a CI server, Java 6, Ant and Maven 2
for a test spin and let me assure you — it’s practically instant, baby! What’s more, the hip cats behind the service have a tutorial that made things quite easy. In fact, I was able to get two open source projects up and running with CI in minutes! Here’s what I did:
First, I logged into my Amazon AWS account and went to the AWS Management Console, clicked the AMIs link and searched for the image ami-d07494b9.
Once I found it, I then right clicked on the instance name and selected the Launch Instance option, which, as you can imagine, launched the instance. Once I did this, I had to wait a few moments (the first time you launch an AMI it takes a minute or two to fire it up, baby).
The CI in a Box image has Tomcat running (with Hudson set as the root context); thus, via the AWS Management Console, you can obtain the public DNS name and accordingly, copy it into your browser’s location box. It might take a second to resolve, but once it does, you should see the Hudson home page in your browser — now you’re ready to configure a CI project!
I figured I’d start easy, so I configured CI in a Box to monitor Fuse Metrics, which is a simple build tool that
analyzes your metrics data, and produces a single page view of whichever metrics you find interesting, including trending graphs and some histographic analysis of your entire code base.
Fuse Metrics uses Ant as a build platform, so within a minute or so, I was able to configure Hudson to monitor the Google code SVN repository and build an artifact anytime there is a change — in this case, the artifact is the resulting jar file from the build process.
Next, I thought I’d try something a bit more challenging — that is, I wanted to see if I could easily configure CI in a Box to build a non-Ant or Maven project; consequently, I decided easyb would be a good test as easyb is built using Gant.
First, I ssh‘ed onto my CI in a Box instance and downloaded the most current version of Gant via wget like so:
$>wget http://dist.codehaus.org/gant/distributions/gant-1.7.0.tgz
Then I unpacked it:
$>tar xvf gant-1.7.0.tgz
Next, I went to the Hudson home page via my browser and proceeded to configure another project; however, in this case, when it came to the Build section, I selected the Execute shell option (FYI, there is a Gant plug-in but recent testing seemed to indicate it is broken or doesn’t work properly with the current version of Gant) and wrote two simple commands to invoke Gant directly on the easyb code base.
Needless to say, baby, things worked wonderfully and in a matter of minutes, I had CI working for easyb!
If you’re looking to spin up a CI process for your project then look no further man — CI in a Box works, well, out of the box, baby!
