-
Notifications
You must be signed in to change notification settings - Fork 128
Detailed instructions for installing Agilefant development environment
Below are example commands on installing these programs for Ubuntu. In this example we will install some of the programs and agilefant to a folder called "projects".
####Java sudo apt-get install python-software-properties
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
sudo apt-get install mysql-server
Download latest version from http://maven.apache.org/download.cgi (e.g. http://www.nic.funet.fi/pub/mirrors/apache.org/maven/maven-3/3.0.5/binaries/apache-maven-3.0.5-bin.tar.gz )
Extract the package under projects folder
Create symbolic link from /home/<USERNAME>/bin/ to projects/apache-maven-<VERSIONNUMBER>/bin/mvn so that you can run mvn anywhere:
mkdir /home/<USERNAME>/bin
cd /home/<USERNAME>/bin
ln -s <PATHTOPROJECTS>/projects/apache-maven-<VERSIONNUMBER>/bin/mvn
Download and install latest version of "Eclipse IDE for Java EE developers" from http://www.eclipse.org/downloads/
If you have multiple versions of Java installed, set the Eclipse to use the version installed earlier in these instructions.
Window >> Preferences >> Java >> Installed JREs
Add the path to the Java version you installed (e.g. /usr/lib/jvm/java-7-oracle (java-7-oracle) )
Download latest version from http://tomcat.apache.org/download-70.cgi (e.g. http://www.nic.funet.fi/pub/mirrors/apache.org/tomcat/tomcat-7/v7.0.39/bin/apache-tomcat-7.0.39.tar.gz )
Extract the package under projects folder
In Eclipse:
Windows >> Preferences
Server >> Runtime Environment
Click "Add..."
Under "Apache" select "Tomcat v7.0"
Click "Next"
Click "Browse..."
Select the folder where you installed Tomcat (e.g. <PATHTOPROJECTS>/projects/apache-tomcat-7.0.39)
Click "Finish"
Help >> Install new software
Work with: <ECLIPSENAME> - http://download.eclipse.org/releases/ (e.g. Juno - http://download.eclipse.org/releases/juno)
Under "Collaboration", select the following two:
m2e - Maven Integration for Eclipse
m2e - slf4j over logback logging
Click next, click next again, agree to terms, click finish.
Help >> Install new software
Click "Add..." to add a new repository. Set location: http://download.eclipse.org/m2e-wtp/releases/
Under "Maven Integration for WTP (Incubation)" select:
m2e-wtp - Maven Integration for WTP (Incubation)
Click next, click next again, agree to terms, click finish.
Window >> Preferences >> Maven >> User Interface >> Open XML page in the POM editor by default
sudo apt-get install git
Go to your projects folder
git clone https://github.com/Agilefant/agilefant
From Eclipse menu: File >> Import
Maven >> Existing Maven Projects
Browse to the agilefant-folder taken from github
Deselect distribution/pom.xml (leave /pom.xml and webapp/pom.xml selected)
Click finish
In terminal, go to your projects folder in (e.g. cd <PATHTOPROJECTS>/projects)
cd agilefant/third-party
./install.sh
cd ..
mvn clean package
mvn -Dmaven.test.skip=true package
In terminal, run:
mysql -u root -p
(enter the root password you used when installing mysql)
CREATE DATABASE agilefant;
GRANT ALL ON agilefant.* to agilefant@localhost IDENTIFIED BY 'agilefant';
Optional: import example data (if you skip this phase, the database will be initialized first time running Agilefant)
USE agilefant;
source <PATH_TO_FILE>/exampledb.sql;
(you can get the latest version of the exampledb also from sourceforge: [http://sourceforge.net/projects/agilefant/files/Agilefant3/exampledb.sql/download|http://sourceforge.net/projects/agilefant/files/Agilefant3/exampledb.sql/download]
N.B.! If you used the exampledb, the username is admin and the password is secret.
Help >> Install new software
Click "Add..." to add a new repository. Set location: http://zeroturnaround.com/update-site
Under "Jrebel for Eclipse" select the following three:
- JRebel
- JRebel for Java EE
- JRebel m2eclipse
Click next, click next again, agree to terms, click finish.
Restart Eclipse, Jrebel should automatically open "Jrebel Config Center" page for you. You can then choose either to evaluate, purchase, or get free Jrebel license.
Right-click agilefant project-folder
Jrebel >> Add Jrebel nature
Window >> Show view >> Other >> Server >> Servers >> Tomcat
Click "new server wizard"
Under "Apache" select "Tomcat v7.0 Server"
Click Next
Select "agilefant" on the left side, and click "Add >"
Click Finish
Double click on the "Tomcat v7.0 Server at localhost" to get the Overview page.
Timeouts >> Start in seconds: 120
Jrebel Integration >> Enable Jrebel Agent
Publishing >> Never publish automatically
Save changes by pressing Ctrl+s
Right click on the "Tomcat v7.0 Server at localhost"
Click start
When server is started, agilefant will be running at http://localhost:8080/agilefant
N.B.! If you used the exampledb, the username is admin and the password is secret.
./set-version.sh <VERSION> (e.g. ./set-version.sh 3.1.0-SNAPSHOT )
git add .
git commit -m "Updated version to <VERSION>"
You can build a war file in terminal. Go to projects folders and run:
build-release.sh
Note: if you are running Eclipse with Jrebel, it is recommended to stop the Tomcat server running in Eclipse. If the server is running while you run the build-release, then at the same time Jrebel will update the changed files, and this will slow down your system.