This is available from http://maven.apache.org
See details here.
Change to the project folder, and run maven.
mvn install
mvn jetty:run
View the running web-application http://localhost:8080/imca/faces/.
Intsall MySql or some other database and set the grants.
>mysql -u root -p mysql> use mysql; mysql> create database imcaadmin; mysql> GRANT ALL ON imcaadmin.* TO imcaadmin@localhost IDENTIFIED BY PASSWORD("P@ssw0rd"); mysql> flush privileges;
Set the imcaadmin password in you maven settings file located in you home directory (~/.m2/settings.xml)
<?xml version="1.0" encoding="UTF-8"?> <settings xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> [...] <profiles> <profile> <id>default</id> <properties> <imcaadmin.password>P@ssw0rd</imcaadmin.password> </properties> </profile> </profiles> <activeProfiles> <activeProfile>default</activeProfile> </activeProfiles> [...] </settings>
Delete (temporarily) the test persistence setting and run the unit test with maven. This will fill the database with some test data.
del src/test/resources/META-INF/persistence.xml mvn clean install