Created
July 14, 2019 13:35
-
-
Save yellow1912/479bea109be6c4559828024654f5adb7 to your computer and use it in GitHub Desktop.
docker compose for open distro with 1 single node
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
odfe-node1: | |
image: amazon/opendistro-for-elasticsearch:1.0.1 | |
container_name: odfe-node1 | |
environment: | |
# - cluster.name=odfe-cluster | |
- node.name=odfe-node1 | |
- discovery.type=single-node | |
# - discovery.seed_hosts=odfe-node1,odfe-node2 | |
# - cluster.initial_master_nodes=odfe-node1,odfe-node2 | |
- bootstrap.memory_lock=true # along with the memlock settings below, disables swapping | |
- "ES_JAVA_OPTS=-Xms512m -Xmx512m" # minimum and maximum Java heap size, recommend setting both to 50% of system RAM | |
ulimits: | |
memlock: | |
soft: -1 | |
hard: -1 | |
nofile: | |
soft: 262144 # maximum number of open files for the Elasticsearch user, set to at least 65536 on modern systems | |
hard: 262144 | |
volumes: | |
- odfe-data1:/usr/share/elasticsearch/data | |
- ./root-ca.pem:/usr/share/elasticsearch/config/root-ca.pem | |
- ./node.pem:/usr/share/elasticsearch/config/node.pem | |
- ./node-key.pem:/usr/share/elasticsearch/config/node-key.pem | |
- ./custom-elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml | |
# - ./internal_users.yml:/usr/share/elasticsearch/plugins/opendistro_security/securityconfig/internal_users.yml | |
ports: | |
- 9200:9200 | |
- 9600:9600 # required for Performance Analyzer | |
networks: | |
- odfe-net | |
# odfe-node2: | |
# image: amazon/opendistro-for-elasticsearch:1.0.1 | |
# container_name: odfe-node2 | |
# environment: | |
# - cluster.name=odfe-cluster | |
# - node.name=odfe-node2 | |
# - discovery.seed_hosts=odfe-node1,odfe-node2 | |
# - cluster.initial_master_nodes=odfe-node1,odfe-node2 | |
# - bootstrap.memory_lock=true | |
# - "ES_JAVA_OPTS=-Xms512m -Xmx512m" | |
# ulimits: | |
# memlock: | |
# soft: -1 | |
# hard: -1 | |
# nofile: | |
# soft: 65536 | |
# hard: 65536 | |
# volumes: | |
# - odfe-data2:/usr/share/elasticsearch/data | |
# networks: | |
# - odfe-net | |
# kibana: | |
# image: amazon/opendistro-for-elasticsearch-kibana:1.0.1 | |
# container_name: odfe-kibana | |
# ports: | |
# - 5601:5601 | |
# expose: | |
# - "5601" | |
# environment: | |
# ELASTICSEARCH_URL: https://odfe-node1:9200 | |
# ELASTICSEARCH_HOSTS: https://odfe-node1:9200 | |
# networks: | |
# - odfe-net | |
volumes: | |
odfe-data1: | |
# odfe-data2: | |
networks: | |
odfe-net: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment