Skip to content

Instantly share code, notes, and snippets.

@amritanshu-pandey
Created April 24, 2018 07:42
Show Gist options
  • Save amritanshu-pandey/816b45c472e6b0bce0b88255c88aec26 to your computer and use it in GitHub Desktop.
Save amritanshu-pandey/816b45c472e6b0bce0b88255c88aec26 to your computer and use it in GitHub Desktop.
Setup Elastic stack (Elastic Search and Kibana) with authentication support on docker
version: '2'
services:
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch-platinum:6.2.4
ports:
- 9200:9200
- 9300:9300
environment:
- 'discovery.type=single-node'
- 'ELASTIC_PASSWORD=elastic'
volumes:
- esdata1=/usr/share/elasticsearch/data
networks: ['stack']
kibana:
image: docker.elastic.co/kibana/kibana:6.2.4
ports:
- 5601:5601
environment:
- 'SERVER_NAME=localhost'
- 'ELASTICSEARCH_URL=http://elasticsearch:9200'
- 'ELASTICSEARCH_USERNAME=elastic'
- 'ELASTICSEARCH_PASSWORD=elastic'
depends_on:
- elasticsearch
networks: ['stack']
networks: {stack: {}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment