version: "3.3"
services:
elasticsearch:
image:
elasticsearch:7.17.1
container_name:
elasticsearch
ports:
- "9200:9200"
- "9300:9300"
networks:
- elastic
environment:
- "discovery.type=single-node"
kibana:
image:
kibana:7.17.1
container_name:
kibana
ports:
- "5601:5601"
networks:
- elastic
depends_on:
- elasticsearch
logstash:
image:
logstash:7.17.1
container_name:
logstash
ports:
- "5044:5044"
# 卷挂载,需要去容器找到对应的配置文件
volumes:
- "$PWD/logstash/pipeline/:/usr/share/logstash/pipeline/"
networks:
- elastic
depends_on:
- elasticsearch
networks:
elastic: