This document will guide you through the installation and configuration of the Camunda standalone web application.The Camunda web application combines Cockpit and Tasklist. The web application is self-contained and includesan embedded process engine, which is configured inside the application. The process engine is configured using theSpring Framework and will automatically start when the application is deployed. The process engine must be configuredto connect to a database (see the database configuration section). By default the process engine will use a built-inidentity service, which can be replaced with LDAP (see the LDAP configuration section).

Embedded vs. Shared Process Engine

Note: Since the Camunda standalone web application uses an embedded process engine it must not be installed to an application server from a Camunda distribution download. Application servers contained in Camunda distributions already provide a shared process engine

Download

If you are an Enterprise Edition Customer, please use the enterprise download page.

As a Community Edition user you can download the Camunda standalone webapp matching your application server here:

Application Server Link
Apache Tomcat camunda-webapp-tomcat-standalone-7.9.0.war
JBoss AS 7 camunda-webapp-jboss-standalone-7.9.0.war
WildFly camunda-webapp-jboss-standalone-7.9.0.war

Deploy

Once you downloaded the camunda-webapp-SERVER-standalone-VERSION.war file youmust deploy it to your application server.Note: Make sure to use a vanilla distribution of your application server, not an application server downloadedfrom Camunda.The exact deployment procedure for web applications depends onyour application server. In case you aren’t sure how to install the application, please refer to your application server documentation.

The default context path for the Camunda web application is /camunda.Note: If you install the Camunda standalone web application on Apache Tomcat by droppingit in the webapps folder, Tomcat will assign the filename of the war file asthe context path. If you want the context path to be /camunda, rename the warfile to camunda.war.

Given that your application is binding to localhost, is running on port 8080and the context path is /camunda, you can then access the Camunda standaloneweb application by using the following url:

http://localhost:8080/camunda/

Database Configuration

The Camunda standalone webapp is initially configured using a file-based H2 databaseand an Apache Commons DBCP datasource. The h2 database is only useful for demo purposes.If you want to use the standalone webapp in production we recommend using a different database.

In order to configure another database, edit the file named WEB-INF/applicationContext.xml inside thecamunda-webapp-SERVER-standalone-VERSION.war. Edit the following section with the appropriate configuration values for your database.

  1. <bean id="dataSource" class="org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy">
  2. <property name="targetDataSource">
  3. <bean class="org.apache.commons.dbcp.BasicDataSource">
  4. <property name="driverClassName" value="org.h2.Driver" />
  5. <property name="url" value="jdbc:h2:./camunda-h2-dbs/process-engine;MVCC=TRUE;TRACE_LEVEL_FILE=0;DB_CLOSE_ON_EXIT=FALSE" />
  6. <property name="username" value="sa" />
  7. <property name="password" value="" />
  8. </bean>
  9. </property>
  10. </bean>
Note: If you configure a different database do not forget to add the corresponding database driver to the classpath of the web application.

As an alternative you can also configure a datasource inside your application server and look it up from the web application.

LDAP Configuration

Adjust the Process Engine Configuration

Initially the Camunda standalone webapp is configured to use a built-in database identity service.If you want to use LDAP instead you have to activate the Camunda LDAP identity service. The fileWEB-INF/applicationContext.xml already contains a configuration example which is deactivated. Inorder to activate it, simply uncomment the lines shown below:

  1. <bean id="processEngineConfiguration" class="org.camunda.bpm.engine.spring.SpringProcessEngineConfiguration">
  2. <!-- ... -->
  3. <property name="processEnginePlugins">
  4. <list>
  5. <!-- Uncomment the following next two lines to activate LDAP -->
  6. <!--<ref bean="ldapIdentityProviderPlugin" />-->
  7. <!--<ref bean="administratorAuthorizationPlugin" />-->
  8. </list>
  9. </property>
  10. </bean>

To configure the LDAP service please adjust the values of the bean named ldapIdentityProviderPlugin as described in the user guide.Do not forget to configure the Administrator Authorization Plugin as well.

HAL Resource Caching

If you use LDAP as Indentity Provider, you should consider activating caching of Users and Groups in the Camunda webapplication. In order to activate this, add the following configuration to the web.xml file of Camunda webapplication:

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
  5. <!-- ... -->
  6. <listener>
  7. <listener-class>org.camunda.bpm.engine.rest.hal.cache.HalRelationCacheBootstrap</listener-class>
  8. </listener>
  9. <context-param>
  10. <param-name>org.camunda.bpm.engine.rest.hal.cache.config</param-name>
  11. <param-value>
  12. {
  13. "cacheImplementation": "org.camunda.bpm.engine.rest.hal.cache.DefaultHalResourceCache",
  14. "caches": {
  15. "org.camunda.bpm.engine.rest.hal.user.HalUser": {
  16. "capacity": 100,
  17. "secondsToLive": 900
  18. },
  19. "org.camunda.bpm.engine.rest.hal.group.HalGroup": {
  20. "capacity": 100,
  21. "secondsToLive": 900
  22. }
  23. }
  24. }
  25. </param-value>
  26. </context-param>
  27. <!-- ... -->
  28. </web-app>

原文: https://docs.camunda.org/manual/7.9/installation/standalone-webapplication/