Team:HFUT CHINA/readme

From 2014.igem.org

HFUT_CHINA

README

 

<div align="justify" class="gallery1"> <div align="justify" class="details"> <div align="justify" class="style"> <div align="justify" class="STYLE1"> <div align="justify" class="STYLE1"> <div align="justify" class="STYLE1"></div> </div> </div> </div> </div> </div>

BioDesigner Server


Softwares Preparation Download Software

 

Software preparation for the deployment on server.

 

All the jars that we used in server has been listed bellow

 

Jdk & Jre

 

The server of BioDesigner is written in JAVA and JSP, and the JSP page will be parsed into servlet. So, first of all, you need to establish the java environment on the server.

 

----Windows Server

 

If you use a server with windows edition, you can download the jdk below.

 

Download Jdk&Jre Here

 

After you install java, you need to add the path of jdk and jre to system: Add the following records to PATH: \%JAVA_HOME%\jdk\bin; Add the following data to CLASSPATH: .;\%JAVA_HOME%\jre\lib;

 

----linux(Ubuntu and Debian Edition)

 

Conduct the commands below to install openjdk:

sudo apt-get update

sudo apt-get install openjdk-7-jdk

After install the openjdk, you need to add the following records to /etc/profile data.

export JAVA_HOME=/usr/local/jdk1.8.0/
export JRE_HOME=/usr/local/jdk1.8.0/jre/
export PATH=$JAVA_HOME/bin:$JAVA_HOME/jre/bin:$PATH
export CLASSPATH=$CLASSPATH:.:$JAVA_HOME/lib:$JAVA_HOME/jre/lib

Apache Tomcat

 

apache tomcat is a jsp server, and the jsp files will be parsed into servlet files, in order to response http request.

 

----Windows

 

You can download apache tomcat at the website below, and tomcat-7 will be a better choice.

 

download tomcat here

 

When you install tomcat, the program may ask you to provide your jdk&jre path.parsing

 

----Linux(Ubuntu and Debian Edition)

 

Conduct the following commands in your terminal:

sudo apt-get update
sudo apt-get install tomcat7

MySQL Server

 

Our project need a database service. There are many kinds of databases in the market. And we use Oracle MySQL database, because it's very powerful and very light. By the way, it's free of charge.

 

----Windows

 

You can download MySQL server at the website below. As for a better performination, we suggest that you choose MySQL 5.x edition.

 

download MySQL here

 

----Linux (Ubuntu and Debian Edition)

 

Conduct the following commands in your terminal:

sudo apt-get update
sudo apt-get install mysql-server

Deployment

 

The deployment process is consisted of 2 steps operation.First of all, you need to push all the jsp and java codes to tomcat server, and the second is to create the database.

 

----server

 

Fortunatly, MyEclipse has compiled all the java codes to class files. So, you will first create a folder in the '%TOMCAT_HOME%\webapp' path, and then, you can copy all the files to your own folder which is created at the first step. At last, you could easily start this project by start your tomcat server.

 

----database

 

We have create an sql file named source.sql, all the data in our database is included. So, after you log in, you create your own database named as you like(we use BioDesiger as our name). If you create a different name, you must modify the hibernate.cfg.xml file. Set the value of the key "hibernate.connection.url" with

 

jdbc:mysql://localhost/Your db name

Also, you may need to update the value of the keys "hibernate.connection.username" and "hibernate.connection.password"

 

After that, you can Insert all the data to your database. You can use "source" command to complete it quickly.So, please change directory to the source.sql file path, and then, log in to your database and conduct the command below:

 

source source.sql