Code Monkey home page Code Monkey logo

addressbook's Introduction

Simple address book web application

Frameworks, Libraries and Tools

  • Spring Framework
  • Hibernate
  • JavaServer Faces
  • Primefaces UI Framework
  • Maven

Installations

Install the required packages.

$ sudo apt-get update
$ sudo apt-get install git mysql-client mysql-server maven

Cloning of files

Copy this repository with the git version control system to get a copy of the project

$ git clone https://github.com/erdemsahin/AddressBook.git
$ cd AddressBook/

Database configuration

Run the database.sql script to create the database, tables, and sample data. Do not forget to enter your own MySQL username in the username!

$ mysql -u username -p < database.sql

Database connection settings

To connect to the database, set the $PROJECT_DIR/main/resources/application.properties file according to your database user name and password.

jdbc.driverClassName=com.mysql.jdbc.Driver
jdbc.url=jdbc:mysql://localhost:3306/addressbook
jdbc.username=root
jdbc.password=123456

hibernate.dialect=org.hibernate.dialect.MySQLDialect

Setting up Tomcat user

Add the following user information to your Tomcat server's $TOMCAT_DIR/conf/tomcat-users.xml file. If you do not have a tomcat server, you can download it here.

<role rolename="manager-gui"/>
<role rolename="manager-script"/>
<role rolename="manager-script"/>
<role rolename="manager-jmx"/>
<role rolename="manager-status"/>
<role rolename="admin-gui"/>
<role rolename="admin-script"/>

<user username="admin" password="password" 
  roles="standard,manager,admin,manager-gui,manager-script,tomcat" />

Running Tomcat server

After configuring the configuration files, you need to run the startup.sh script to run the tomcat server.

$ cd $TOMCAT_DIR/bin
$ ./startup.sh

Deploying the project to the server

You only need to enter the mvn tomcat7:deploy command to deploy the project. If a problem occurs, run the mvn clean command and then run the mvn tomcat7:redeploy command to redeploy the project.

$ mvn clean
$ mvn tomcat7:deploy
$ mvn tomcat7:redeploy

Completed

The AddressBook application is now running. Open the http://localhost:8080/AddressBook page from your web browser. You will have access to the persons list.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.