Я пытался использовать официальные изображения Kibana и ElasticSearch, но они просто выходили с сообщениями об ошибках.И через несколько секунд после запуска состояние контейнеров выглядит так:
Name State
------------------------------
elasticsearch Exit 1
elasticsearch1 Exit 78
mongotest_kafka_1 Up
mongotest_kibana_1 Exit 1
Сообщение об ошибке для одного из образов:
elasticsearch1 | ERROR: [1] bootstrap checks failed
elasticsearch1 | [1]: max virtual memory areas vm.max_map_count [65530] is too low, increase to at least [262144]
elasticsearch1 | [2018-06-04T09:37:17,274][INFO ][o.e.n.Node ] [L0Tp7dx] stopping ...
elasticsearch1 | [2018-06-04T09:37:17,289][INFO ][o.e.n.Node ] [L0Tp7dx] stopped
elasticsearch1 | [2018-06-04T09:37:17,289][INFO ][o.e.n.Node ] [L0Tp7dx] closing ...
elasticsearch1 | [2018-06-04T09:37:17,296][INFO ][o.e.n.Node ] [L0Tp7dx] closed
elasticsearch1 | [2018-06-04T09:37:17,298][INFO ][o.e.x.m.j.p.NativeController] Native controller process has stopped - no new native processes can be started
Я не уверен, есть ли какие-то конфигурациив моем docker-compose.yml не так:
version: '3.3'
services:
kafka:
image: spotify/kafka
ports:
- "9092:9092"
environment:
- ADVERTISED_HOST=localhost
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:6.2.4
container_name: elasticsearch
environment:
- cluster.name=docker-cluster
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- esdata1:/usr/share/elasticsearch/data
ports:
- 9200:9200
networks:
- esnet
elasticsearch1:
image: docker.elastic.co/elasticsearch/elasticsearch:6.2.4
container_name: elasticsearch1
environment:
- cluster.name=docker-cluster
- bootstrap.memory_lock=true
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- "discovery.zen.ping.unicast.hosts=elasticsearch"
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- esdata2:/usr/share/elasticsearch/data
networks:
- esnet
kibana:
image: docker.elastic.co/kibana/kibana:6.2.4
environment:
SERVER_NAME: kibana
SERVER_NAME: "0"
ELASTICSEARCH_URL: http://elasticsearch:9200
ELASTICSEARCH_USERNAME: elastic
ELASTICSEARCH_PASSWORD: changeme
XPACK_MONITORING_UI_CONTAINER_ELASTICSEARCH_ENABLED: "true"
networks:
- esnet
volumes:
esdata1:
driver: local
esdata2:
driver: local
networks:
esnet: