Giter Club home page Giter Club logo

wxshop's Introduction

Deployment Guide

中文文档

  • This is a distributed application, there are two parts, they use Dubbo RPC communicate with each other.

    • Main module: Be responsible for processing HTTP requests (including static resources), updating product, store, and shopping cart information.
    • Order module: Be responsible for the order module.
  • Application dependency:

    • Redis: Maintain distributed login status.
    • Mysql: Store all data.
    • Zookeeper: Be as the registration center of Dubbo.
    • NGINX: implementation of multi-instance deployment and load balancing
  • Deployment steps

    • docker run -d -v /path/to/wxshop-data:/var/lib/mysql -p 3306:3306 -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=wxshop --name=wxshop-mysql mysql
    • docker run -p 6379:6379 -d redis
    • docker run -p 2181:2181 -d zookeeper
    • Wait for half a minute, wait for the container to start. -Create order database
    docker exec -it wxshop-mysql mysql -uroot -proot -e 'create database if not exists `order`
    
    • ./mvnw install -DskipTests
    • ./mvnw flyway:migrate -pl wxshop-main
    • ./mvnw flyway:migrate -pl wxshop-order
  • Launch the app itself

    • Run in the first window java -jar wxshop-order/target/wxshop-order-0.0.1-SNAPSHOT.jar
    • Run in the second window java -jar wxshop-main/target/wxshop-main-0.0.1-SNAPSHOT.jar
  • open http://localhost:8080

Database/Redis/ZooKeeper configuration

If your mysql/redis/zookeeper server is not started on localhost, but on another ip, then you need to replace localhost globally with the corresponding ip

**Note, only replace localhost, don't replace 127.0.0.1! ! ! **

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.