欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

使用Docker安装Elasticsearch Kibana

程序员文章站 2022-07-14 11:46:03
...

准备docker-compose.yml文件,如下所示为启动一个单节点Elasticsearch集群和Kibana面板:

version: "2.2"
services:
  elasticsearch:
    image: elasticsearch:7.4.2
    ports:
      - "9200:9200"
      - "9300:9300"
    networks:
      - elastic
    environment:
      - "discovery.type=single-node"

  kibana:
    image: kibana:7.4.2
    ports:
      - "5601:5601"
    depends_on:
      - elasticsearch
    networks:
      - elastic

networks:
  elastic:
    driver: bridge

运行

docker-compose up -d

访问 http://localhost:5601/ 即可看到Kibana面板。

参考链接:

Install Elasticsearch with Docker | Elasticsearch Reference [7.4] | Elastic

elasticsearch - Docker Hub

kibana - Docker Hub