Deploying a WAR file from Jenkins to Tomcat

The three main approaches to deploying web applications for integration tests are as follows:

  • Run the web app locally in a container such as Jetty, brought to life during a Jenkins Job. The applications database is normally in-memory, and the data stored is not persisted past the end of the Job. This saves cleaning up and eliminates unnecessary dependency on the infrastructure.
  • A nightly build is created where the application is rebuilt regularly through a scheduler. This normally happens at night when no one is using the infrastructure, hence the name. No polling of the SCM is needed. The advantage of this approach are a distributed team that knows exactly when and at which fixed web address a new build ...

Get Jenkins Continuous Integration Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.