Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »


  • Check out Cargo from SVN into a CARGOHOME directory (wherever you want on your machine)
  • Install Maven 1 or Maven 2. Verify your installation works by typing maven --version (for Maven 1) or mvn --version (for Maven 2) at a command prompt.

Building with Maven 1

First time build


The Cargo build contains functional tests. Those tests are run on different containers. The first time you build Cargo it will download those container distributions which will take some time (the containers are installed into CARGOHOME/target/installs). If you want to tell Cargo to run only on some specific container, see below.

  • Go to CARGOHOME and type maven. This will build the full Cargo project and the distribution jars will be generated in CARGOHOME/distribution/target. The functional tests will be run on the default container set.
  • If you want to build a single project, cd to that project and type maven. Note that the build will fail if you've never built the dependent projects. Thuse it is recommended to build the full Cargo project at least once.
Selecting containers

The default list of containers to run on depends on the subproject being built:

  • For the java samples, the list is in CARGOHOME/samples/java/ If you want to define a different list, simply create a file either in your home directory or in samples/java. In this file, create a cargo.containers listing the containers you wish to run on. For example if you only want to run on Tomcat 5.x you'd write:
  • For the Ant samples, the list is in CARGOHOME/samples/extensions/ant/ Once again if you want to define a different list, simply create a file either in your home directory or in samples/extensions/ant.
  • For the Maven1 samples, the list is in CARGOHOME/samples/extensions/maven/
  • Type maven -o to work offline. This improves the build speed as Maven 1 does not check for updates on the remote repository for SNAPSHOTs.

Building with Maven 2


  • No labels