1 extracting JDK to/usr/lib
sudo tar zxvf./jdk-8u45-linux-x64.tar.gz-c/usr/lib
2 extracting Tomcat to/OPT
sudo tar zxvf./apache-tomcat-8.0.22.tar.gz-c/opt
3 Configuring the Environment (modify/etc/profile):
On the last side add:
Export java_home=/usr/lib/jdk1.8.0_45/
Export tomcat_home=/opt/apache-tomcat-8.0.22/
Export JRE_HOME=${JAVA_HOME}/JRE
Export Classpath=.:${java_home}/lib:${jre_home}/lib
Export path= $PATH: $JAVA _home/bin: $TOMCAT _home/bin
4 Set up JDK for your own JDK (instead of JDK):
sudo update-alternatives--install/usr/bin/java Java/usr/lib/jdk1.8.0_45/bin/java 300
sudo update-alternatives--install/usr/bin/javac Javac/usr/lib/jdk1.8.0_45/bin/javac 300
sudo update-alternatives--install/usr/bin/jar Jar/usr/lib/jdk1.8.0_45/bin/jar 300
sudo update-alternatives--config java
Command line:
5 test JDK and tomcat:java-version;. /startup
6 adding users to Tomcat:
sudo gedit/opt/apache-tomcat-8.0.22/conf/tomcat-users.xml
Next to </tomcat-users> add:
<role rolename= "admin"/>
<role rolename= "Manager"/>
<user username= "admin" password= "admin" roles= "admin"/>
<user username= "Both" password= "both" roles= "Admin,manager"/>
<user username= "Manager" password= "manager" roles= "manager"/>
This means that the both account has both admin and manager roles
7 Unzip eclipse to/user/lib:
sudo tar zxvf./eclipse-jee-luna-sr2-linux-gtk-x86_64.tar.gz-c/usr/lib8
8 Set the path to Tomcat in eclipse: Select the third: Server path followed to bin; deployment path to WebApp under Tomcat;
Set up the MAVEN environment to the user directory to build the. M2 folder. Put in the configuration file setting.xml;
ECLIPSE+JDK+TOMCAT installation and environment configuration under Linux