Combat: Build microservices based on spring Cloud + Docker

Source: Internet
Author: User
Tags docker compose

This series records the actual combat process of learning spring-cloud-microservice-example, and analyzes the use of spring Cloud + Docker to build an end-to-end microservices architecture technology.


0. Prior to installation, the following software is required for installation.

    1. Maven 3

    2. Java 8

    3. Docker

    4. Docker Compose


My environment

Ubuntu 16.04
Java OpenJDK 1.8.0
Docker 18.03.1-ce
Docker-compose 1.8.0

1. Cloning or copying works

$ Docker Clone Https://github.com/kbastani/spring-cloud-microservice-example.git


2. Building the Project

Running in the project root directory

$ mvn Clean Install

This step is performed for a period of time, depending on the speed of the network, so MAVEN repository and Docker libraries are best used for domestic sources.

This step will download all dependencies and compile the project. Once all the services have been built successfully, theMaven Docker plugin will automatically build all the images and save them to your local Docker regitsry.

If this step succeeds, you will see in the Command Number window at the end

3. Launch the cluster with Docker compose

Executed under the Spring-cloud-microservice-example/docker directory

$ docker-compose Up

This step will take a few minutes.


4. Check the results of the experiment

Open the browser and visit http://localhost:8761/to see Eureka Service's Dashboard

Enter in the browser address bar: Http://localhost:10000/movie can see the movie service rest API

To be Continued ...

Combat: Build microservices based on spring Cloud + Docker

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.