Setting up ELK Stack on the machine

Before we try to send any logs from our application to Logstash, we have to configure ELK Stack on the local machine. The most suitable way to run it is through Docker containers. All the products in the stack are available as Docker images. There is a dedicated Docker registry hosted by Elastic Stack's vendor. A full list of published images and tags can be found at www.docker.elastic.co. All of them use centos:7 as the base image. 

We will begin from the Elasticsearch instance. Its development can be started with the following command:

docker run -d --name es -p 9200:9200 -p 9300:9300 -e "discovery.type=single-node" docker.elastic.co/elasticsearch/elasticsearch:6.1.1

Running Elasticsearch in development ...

Get Mastering Spring Cloud now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.