Hi,
My apologies if this question has already been answered.
Question: How do I add a servlet filter as described here to enable the REST API for Camunda Community version? My installed version uses Tomcat server.
My background:
I’ve never used Java or Tomcat. Have a .NET background, hosting web apps with IIS.
I’ve completed the first two Camunda tutorial videos using the community software version.
If someone could advise what steps I need to configure what I assume is an XML file somewhere, I’d be grateful!
Thanks,
David
This question is quite old. But as I was looking for the right repositories, recently too, this may help for future camunda beginners.
In order to be able to use the camunda rest api on a Servlet Container/Application Server you have to do the following things:
- clone repository: https://github.com/camunda/camunda-bpm-platform
- The repository contains tags which indicate the camunda version. Currently 7.13.0 is the latest stable version. So checkout the tag with the latest version.
- Navigate to engine-rest/assembly
- this maven project uses the assembly plugin. So to create the .war-files execute
mvn clean compile assembly:single
- maven will build multiple .war-files (for every supported Servlet Container/Application Server one .war-file is built; In this question tomcat was mentioned, so just take camunda-engine-rest-7.13.0-tomcat.war )
Security
Authentication is disabled by default for devlopment purposes. For production it is highly recommended to enable Authentication.
To enable the Servlet Security Filter navigate to src/main/runtime/<<ApplicationServer>>/webapp/WEB-INF/web.xml
where ApplicationServer is the Application Server/Servlet Container of your choice.
Open the corresponding web.xml and uncomment the filter. Build the .war-files again using the command in 4. and there you go. You built the .war-file including the security filter. You can deploy the .war to the Server of your choice.
1 Like