This example demonstrates how you can build a normal WAR file, containing Camunda engine and Webapps, to deploy it inside Web container.
To achieve this you need to configure your project to produce a WAR file and additionally
declare the embedded container dependencies in provided
scope:
...
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
<scope>provided</scope>
</dependency>
...
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<failOnMissingWebXml>false</failOnMissingWebXml>
</configuration>
</plugin>
...
</plugins>
</build>
...
You can then build the WAR by calling mvn clean install
, deploy it in Tomcat and try the URL:
http://localhost:8080/camunda-bpm-spring-boot-starter-example-war-0.0.1-SNAPSHOT/app/
Or you can try it via Cargo Maven Plugin:
mvn clean verify org.codehaus.cargo:cargo-maven2-plugin:run
and point your browser to
http://localhost:8080/camunda-bpm-spring-boot-starter-example-war/app/
The project also contains integration test to show how this can be tested.