How to install Apache Continuum

Last Modified: Thu, 08 Jan 2009 21:10:00 +0000 ; Created: Thu, 08 Jan 2009 21:10:00 +0000

Apache Continuum is an automated build and reporting system for Maven or Ant Java projects. It is nice because it will automatically check out from source control a project and build it. Any errors found during the build process can then be e-mailed to you. This is nice because it allows an automated build to run every X hours (or whatever you want) with the latest code from source control. This allows one to catch an error that breaks the build a developer may have made when checking in code. It also provides a web interface for viewing build history and reports.

Unfortunately the documentation on setting up Continuum isn't very good. Below is my quick start guide to getting Continuum running. This assumes Windows XP, but the instructions should work on Linux as well.

Pre-requesites:
  1. Download Apache Continuum (these instructions were done with version 1.2.2)
  2. Java JDK (javac) in your system path
  3. For Windows a user account to run the service
    • You should not use LocalSystem as you need a separate user home directory
  4. Maven 2.0.9+ in your system path
  5. JAVA_HOME system environment variable that points to your JDK
  6. Subversion command line client (svn) in your system path
  7. TCP port 8080 free
  8. A settings.xml for your Maven in the correct place (see instructions below)
Installation Steps (Windows):
  1. Unzip the Apache Continuum distro into whatever location
  2. Create the Windows user account
    • Users group only, Administrators is not necessary
  3. Create the Windows' user profile on the system
    • cmd /runas:ContinuumUser cmd
  4. Copy your Maven settings file into the profile-folder/.m2/settings.xml
    • Don't forget to adjust the file security permissions if necessary
  5. If your SVN repository requires auth for read-only access
    • cmd /runas:ContinuumUser cmd
    • svn list https://your-repo/svn/project
  6. Set recursively the Apache Continuum folder security permissions and ownership to your Windows' Continuum user
  7. Install the Continuum service by running c:\apache-continuum-x.y.z\bin\continuum.bat install
  8. Open up the Services control panel (run services.msc)
  9. Edit the "Apache Continuum" service
    1. Log On tab
    2. Log on as: "This account"
    3. Enter in the Windows' Continuum user account you created
    4. Click on the OK button
  10. Edit c:\apache-continuum-x.y.z\conf\jetty.xml
    1. You should probably open it in WordPad
    2. Search for "mail.smtp.host"
    3. Inbetween the "Put" tags insert the hostname of your SMTP e-mail server
      • You will probably need to remove the "localhost" default setting
    4. Save the file and close it
  11. Start the "Apache Continuum" service
  12. Be very patient as it takes a while to load
Post Steps:
  1. Open your web browser to http://localhost:8080/continuum
  2. Follow the first time configuration wizard
  3. When adding a Maven project "POM Url" means the URL to the pom.xml file in source control
    • Example: https://svn-server/svn/project/trunk/pom.xml