Table of Contents |
---|
Introduction
Info |
---|
If you would prefer to install DuraCloud from a binary distribution, you can find instructions for that process here. |
...
- Maven 2.2.1 or above
- Tomcat 6.x or above
- Java 6 7 (note: the djatoka service has compatibility issues with open-jdk)
- Subversion
...
Build and deploy the DuraCloud web applications
Check out latest stable release from Subversion repository
Code Block svn co https://svn.duraspace.org/duracloud/tags/duracloud-2.1.0
Set environment variables
Code Block export JAVA_OPTS="-XX:MaxPermSize=256m" export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=1024m"
- Configure Tomcat
Add to $CATALINA_HOME/conf/tomcat-users.xml
No Format <tomcat-users> <role rolename="manager"/> <role rolename="admin"/> <user username="[ANY-USERNAME]" password="[ANY-PASSWORD]" roles="admin,manager"/> </tomcat-users>
Start tomcat
Code Block $CATALINA_HOME/bin/startup.sh
- Configure Maven2
Add tomcat user to $M2_HOME/conf/settings.xml
No Format <servers> <server> <id>tomcat-server</id> <username>[ANY-USERNAME]</username> <password>[ANY-PASSWORD]</password> </server> </servers>
- Build
From top of source tree
Code Block mvn clean install
Set up the OSGi services container
This step assumes the successful completion of the previous build instructions
Panel | ||
---|---|---|
| ||
|
Panel | ||||||
---|---|---|---|---|---|---|
| ||||||
|
...
- Use the application initialization (app-config) utiltiy to configure the deployed DuraCloud applications
Build app-config utility, from within the //app-config module
Code Block mvn assembly:assembly
Run the app-config utility
Code Block java -jar target/app-config-[VERSION]-driver.jar <init.props>
- The init.props file is a configuration file which specifies all of the information necessary for the DuraCloud applications to run. An example of this file can be found at //app-config/src/main/resources/init.props. This file will need to be updated to match your environment.
- When the app-config utility completes successfully, the last line of output printed to the console will be the word "success". If this is not the case, check that your configuration file includes the correct information.
...
Optional items
Code coverage
If you plan on using Clover, the following element needs to be added to your maven 'settings.xml'
No Format <profiles> <profile> <id>profile-clover</id> <activation> <property> <name>profile</name> <value>clover</value> </property> </activation> <properties> <cloverLicense>[LOCATION-OF-clover.license-FILE]</cloverLicense> </properties> </profile> </profiles>
To run clover
Code Block mvn clover2:instrument clover2:aggregate clover2:clover -Pprofile-clover
- A report will be generated in the following directory:
//target/site/clover/
...
- Assuming that the OSGi services container is set up and running (as described above), tests that deploy services into the OSGi environment may be run
From inside the //integration-test module
Code Block mvn install -PrunServicesAdminTests
...
- This tool provides a commandline interface for interacting with the 'services-admin' installed in a running OSGi container (see notes above for starting the container)
To build and run the CLI, from within the //servicesadminclient module
Code Block mvn assembly:assembly java -cp target/servicesadminclient-[VERSION]-cli.jar
Building Java client packages
To create a distributable zip of the storeclient, serviceclient, or reportclient which includes their dependencies, from within the project directory (//storeclient, //serviceclient, //reportclient) run
Code Block mvn install -Ppackage-client
- The packaged zip will be found under the project's target directory
...