mkdir -p /docker/es/config data plugins
mkdir -p /docker/kibana/config
chmod 777 -R /docker/es/data
echo "http.host: 0.0.0.0">/docker/es/config/elasticsearch.yml
[root@localhost /]# cat /docker/kibana/config/kibana.yml
server.name: kibana
server.host: "0.0.0.0"
elasticsearch.hosts: [ "http://10.9.236.182:9200" ]
#elasticsearch.url: "http://10.9.236.182:9200"
xpack.monitoring.ui.container.elasticsearch.enabled: true
docker run --name es -d -e ES_JAVA_OPTS="-Xms2g -Xmx2g" -e "discovery.type=single-node" -p 9200:9200 -p 9300:9300 \
--restart=always \
-v /docker/es/config/es.yml:/usr/share/elasticsearch/config/elasticsearch.yml \
-v /docker/es/data:/usr/share/elasticsearch/data \
-v /docker/es/plugins:/usr/share/elasticsearch/plugins \
elasticsearch:6.7.0
docker run -d \
--name=kibana \
--restart=always \
-e ELASTICSEARCH_HOSTS=http://10.9.236.182:9200 \
-p 5601:5601 \
-v /docker/kibana/config/kibana.yml \
kibana:6.7.0