Wiki

Clone wiki

Creedo / Using Maven

Creedo relies on a Maven installation for a number of central tasks. Maven is a tool, that greatly simplifies several compilation or deployment related tasks. Make sure you have Maven installed on your machine. You can download the latest version from here.

Compilation

In order to automatically download all needed dependencies of Creedo and compile the project, go into the Creedo directory and run

#!shell
mvn clean install

Generate IDE project configuration files

For Eclipse run

#!shell
mvn eclipse:eclipse
Start Eclipse and import the project. If Eclipse doesn't fully recognize the project as a web application (e.g. there is no Targeted Runtimes entry in the project properties) try the following: 1) Right-click on the project in the project explorer view, then select "Configure" -> "Convert to Maven project". 2) Right-click it again, select the menu item "Maven" (which wasn't there before) and select "Update project...". 3) Click OK. Now there should be an entry "Targeted Runtimes" in the project properties.

For IntelliJ IDEA

#!shell
mvn idea:idea

Note that in either IDE, you still have to manually configure the runtime environment, meaning to configure a Tomcat in your IDE (if not already done) and create a runtime configuration for deploying to this Tomcat.

Deploy on own Tomcat

If you want to deploy Creedo to an existing Tomcat, simply execute

#!shell
mvn package
This will compile Creedo and create a war file that can be deployed to a server like Tomcat. You find the war file in the directory target. You have to provide your customized application.properties file to Tomcat in order for Creedo to be able to find this. The way to do that is a little bit arduous, but it's the way to go. Create a file Creedo.xml with the following content (adjusted to your situation):

#!xml

<Context>
    <Environment name="application.config.file" value="/path/to/your/application.properties" type="java.lang.String"/>
</Context>
Put this file into a specific directory of Tomcat:

In Ubuntu it is

#!shell

/var/lib/tomcat7/conf/Catalina/localhost

In Windows go to your Tomcat directory and the go to

#!shell

your-Tomcat-directory/work/Catalina/localhost

Then deploy the war file (by copying it to the webapps directory or using Tomcat's web interface).

Start Creedo on local Tomcat

Probably the easiest way to start Creedo is simply by letting Maven handle the Tomcat startup.

#!shell

mvn -Dapplication.config.file=/path/to/your/application.properties tomcat7:run
This will download and start Tomcat7 and deploy Creedo. Use your browser to open http://localhost:8080/Creedo to access it.

Updated