Update es-cluster to 6.2.3
This commit is contained in:
parent
452849a5b0
commit
26ffb9c805
5
templates/es-cluster/4/README.md
Normal file
5
templates/es-cluster/4/README.md
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
# Elasticsearch Cluster
|
||||||
|
|
||||||
|
A scalable Elasticsearch cluster
|
||||||
|
|
||||||
|
WARN: To avoid vm.max_map_count errors you could set "Update host sysctl" to true. Then param vm.max_map_count will be update to 262144 if it's less in your hosts.
|
122
templates/es-cluster/4/docker-compose.yml.tpl
Normal file
122
templates/es-cluster/4/docker-compose.yml.tpl
Normal file
@ -0,0 +1,122 @@
|
|||||||
|
version: '2'
|
||||||
|
services:
|
||||||
|
es-master:
|
||||||
|
labels:
|
||||||
|
io.rancher.scheduler.affinity:container_label_soft_ne: io.rancher.stack_service.name=$${stack_name}/$${service_name}
|
||||||
|
io.rancher.container.hostname_override: container_name
|
||||||
|
io.rancher.sidekicks: es-storage{{- if eq .Values.UPDATE_SYSCTL "true" -}},es-sysctl{{- end}}
|
||||||
|
image: docker.elastic.co/elasticsearch/elasticsearch:6.2.3
|
||||||
|
environment:
|
||||||
|
- "cluster.name=${cluster_name}"
|
||||||
|
- "node.name=$${HOSTNAME}"
|
||||||
|
- "bootstrap.memory_lock=true"
|
||||||
|
- "xpack.security.enabled=false"
|
||||||
|
- "ES_JAVA_OPTS=-Xms${master_heap_size} -Xmx${master_heap_size}"
|
||||||
|
- "discovery.zen.ping.unicast.hosts=es-master"
|
||||||
|
- "discovery.zen.minimum_master_nodes=${minimum_master_nodes}"
|
||||||
|
- "node.master=true"
|
||||||
|
- "node.data=false"
|
||||||
|
ulimits:
|
||||||
|
memlock:
|
||||||
|
soft: -1
|
||||||
|
hard: -1
|
||||||
|
nofile:
|
||||||
|
soft: 65536
|
||||||
|
hard: 65536
|
||||||
|
mem_limit: ${master_mem_limit}
|
||||||
|
mem_swappiness: 0
|
||||||
|
cap_add:
|
||||||
|
- IPC_LOCK
|
||||||
|
volumes_from:
|
||||||
|
- es-storage
|
||||||
|
|
||||||
|
es-data:
|
||||||
|
labels:
|
||||||
|
io.rancher.scheduler.affinity:container_label_soft_ne: io.rancher.stack_service.name=$${stack_name}/$${service_name}
|
||||||
|
io.rancher.container.hostname_override: container_name
|
||||||
|
io.rancher.sidekicks: es-storage{{- if eq .Values.UPDATE_SYSCTL "true" -}},es-sysctl{{- end}}
|
||||||
|
image: docker.elastic.co/elasticsearch/elasticsearch:6.2.3
|
||||||
|
environment:
|
||||||
|
- "cluster.name=${cluster_name}"
|
||||||
|
- "node.name=$${HOSTNAME}"
|
||||||
|
- "bootstrap.memory_lock=true"
|
||||||
|
- "xpack.security.enabled=false"
|
||||||
|
- "discovery.zen.ping.unicast.hosts=es-master"
|
||||||
|
- "ES_JAVA_OPTS=-Xms${data_heap_size} -Xmx${data_heap_size}"
|
||||||
|
- "node.master=false"
|
||||||
|
- "node.data=true"
|
||||||
|
ulimits:
|
||||||
|
memlock:
|
||||||
|
soft: -1
|
||||||
|
hard: -1
|
||||||
|
nofile:
|
||||||
|
soft: 65536
|
||||||
|
hard: 65536
|
||||||
|
mem_limit: ${data_mem_limit}
|
||||||
|
mem_swappiness: 0
|
||||||
|
cap_add:
|
||||||
|
- IPC_LOCK
|
||||||
|
volumes_from:
|
||||||
|
- es-storage
|
||||||
|
depends_on:
|
||||||
|
- es-master
|
||||||
|
|
||||||
|
es-client:
|
||||||
|
labels:
|
||||||
|
io.rancher.scheduler.affinity:container_label_soft_ne: io.rancher.stack_service.name=$${stack_name}/$${service_name}
|
||||||
|
io.rancher.container.hostname_override: container_name
|
||||||
|
io.rancher.sidekicks: es-storage{{- if eq .Values.UPDATE_SYSCTL "true" -}},es-sysctl{{- end}}
|
||||||
|
image: docker.elastic.co/elasticsearch/elasticsearch:6.2.3
|
||||||
|
environment:
|
||||||
|
- "cluster.name=${cluster_name}"
|
||||||
|
- "node.name=$${HOSTNAME}"
|
||||||
|
- "bootstrap.memory_lock=true"
|
||||||
|
- "xpack.security.enabled=false"
|
||||||
|
- "discovery.zen.ping.unicast.hosts=es-master"
|
||||||
|
- "ES_JAVA_OPTS=-Xms${client_heap_size} -Xmx${client_heap_size}"
|
||||||
|
- "node.master=false"
|
||||||
|
- "node.data=false"
|
||||||
|
ulimits:
|
||||||
|
memlock:
|
||||||
|
soft: -1
|
||||||
|
hard: -1
|
||||||
|
nofile:
|
||||||
|
soft: 65536
|
||||||
|
hard: 65536
|
||||||
|
mem_limit: ${client_mem_limit}
|
||||||
|
mem_swappiness: 0
|
||||||
|
cap_add:
|
||||||
|
- IPC_LOCK
|
||||||
|
volumes_from:
|
||||||
|
- es-storage
|
||||||
|
depends_on:
|
||||||
|
- es-master
|
||||||
|
|
||||||
|
es-storage:
|
||||||
|
labels:
|
||||||
|
io.rancher.container.start_once: true
|
||||||
|
network_mode: none
|
||||||
|
image: rawmind/alpine-volume:0.0.2-1
|
||||||
|
environment:
|
||||||
|
- SERVICE_UID=1000
|
||||||
|
- SERVICE_GID=1000
|
||||||
|
- SERVICE_VOLUME=/usr/share/elasticsearch/data
|
||||||
|
volumes:
|
||||||
|
- es-storage-volume:/usr/share/elasticsearch/data
|
||||||
|
|
||||||
|
{{- if eq .Values.UPDATE_SYSCTL "true" }}
|
||||||
|
es-sysctl:
|
||||||
|
labels:
|
||||||
|
io.rancher.container.start_once: true
|
||||||
|
network_mode: none
|
||||||
|
image: rawmind/alpine-sysctl:0.1
|
||||||
|
privileged: true
|
||||||
|
environment:
|
||||||
|
- "SYSCTL_KEY=vm.max_map_count"
|
||||||
|
- "SYSCTL_VALUE=262144"
|
||||||
|
{{- end}}
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
es-storage-volume:
|
||||||
|
driver: ${VOLUME_DRIVER}
|
||||||
|
per_container: true
|
111
templates/es-cluster/4/rancher-compose.yml
Normal file
111
templates/es-cluster/4/rancher-compose.yml
Normal file
@ -0,0 +1,111 @@
|
|||||||
|
version: '2'
|
||||||
|
catalog:
|
||||||
|
name: Elasticsearch Cluster
|
||||||
|
version: 6.2.3-rancher1
|
||||||
|
description: Scalable Elasticsearch Cluster
|
||||||
|
|
||||||
|
questions:
|
||||||
|
- variable: "cluster_name"
|
||||||
|
type: "string"
|
||||||
|
required: true
|
||||||
|
label: "Cluster name"
|
||||||
|
description: "Name of the Elasticsearch Cluster"
|
||||||
|
default: "es-cluster"
|
||||||
|
|
||||||
|
- variable: "UPDATE_SYSCTL"
|
||||||
|
label: "Update host sysctl:"
|
||||||
|
description: |
|
||||||
|
Set true to avoid vm.max_map_count errors.
|
||||||
|
WARN: If set true, host param vm.max_map_count will be update to 262144.
|
||||||
|
default: false
|
||||||
|
required: true
|
||||||
|
type: enum
|
||||||
|
options:
|
||||||
|
- false
|
||||||
|
- true
|
||||||
|
|
||||||
|
- variable: "master_heap_size"
|
||||||
|
type: "string"
|
||||||
|
required: true
|
||||||
|
label: "Heap size (master nodes)"
|
||||||
|
description: "Heap size to be allocated for Java (master nodes)"
|
||||||
|
default: "512m"
|
||||||
|
|
||||||
|
- variable: "master_mem_limit"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "Memory limit in byte (master nodes)"
|
||||||
|
description: "Memory limit in Byte per elasticsearch container. AT LEAST double the heap size! (master nodes)"
|
||||||
|
default: 1073741824
|
||||||
|
|
||||||
|
- variable: "data_heap_size"
|
||||||
|
type: "string"
|
||||||
|
required: true
|
||||||
|
label: "Heap size (data nodes)"
|
||||||
|
description: "Heap size to be allocated for Java (data nodes)"
|
||||||
|
default: "512m"
|
||||||
|
|
||||||
|
- variable: "data_mem_limit"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "Memory limit in byte (data nodes)"
|
||||||
|
description: "Memory limit in Byte per elasticsearch container. AT LEAST double the heap size! (data nodes)"
|
||||||
|
default: 1073741824
|
||||||
|
|
||||||
|
- variable: "client_heap_size"
|
||||||
|
type: "string"
|
||||||
|
required: true
|
||||||
|
label: "Heap size (client nodes)"
|
||||||
|
description: "Heap size to be allocated for Java (client nodes)"
|
||||||
|
default: "512m"
|
||||||
|
|
||||||
|
- variable: "client_mem_limit"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "Memory limit in byte (client nodes)"
|
||||||
|
description: "Memory limit in Byte per elasticsearch container. AT LEAST double the heap size! (client nodes)"
|
||||||
|
default: 1073741824
|
||||||
|
|
||||||
|
- variable: "minimum_master_nodes"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "# of minimum Master Nodes"
|
||||||
|
description: "Set the number of required master nodes to reach quorum. Sets initial scale to this value as well"
|
||||||
|
default: 3
|
||||||
|
|
||||||
|
- variable: "initial_data_nodes"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "# of initial data nodes"
|
||||||
|
description: "Set the initial number of data nodes"
|
||||||
|
default: 2
|
||||||
|
|
||||||
|
- variable: "initial_client_nodes"
|
||||||
|
type: "int"
|
||||||
|
required: true
|
||||||
|
label: "# of initial client nodes"
|
||||||
|
description: "Set the initial number of client nodes"
|
||||||
|
default: 1
|
||||||
|
|
||||||
|
- variable: "VOLUME_DRIVER"
|
||||||
|
description: "The VOLUME driver to associate with this server"
|
||||||
|
label: "VOLUME Driver"
|
||||||
|
required: true
|
||||||
|
default: "local"
|
||||||
|
type: enum
|
||||||
|
options:
|
||||||
|
- local
|
||||||
|
- rancher-nfs
|
||||||
|
- rancher-efs
|
||||||
|
- rancher-ebs
|
||||||
|
|
||||||
|
services:
|
||||||
|
|
||||||
|
es-master:
|
||||||
|
scale: ${minimum_master_nodes}
|
||||||
|
|
||||||
|
es-data:
|
||||||
|
scale: ${initial_data_nodes}
|
||||||
|
|
||||||
|
es-client:
|
||||||
|
scale: ${initial_client_nodes}
|
@ -1,5 +1,5 @@
|
|||||||
name: Elasticsearch Cluster 5.5.1
|
name: Elasticsearch Cluster 6.2.3
|
||||||
description: |
|
description: |
|
||||||
Elasticsearch, you know for search!
|
Elasticsearch, you know for search!
|
||||||
version: 5.5.1-rancher1
|
version: 6.2.3-rancher1
|
||||||
category: ELK
|
category: ELK
|
||||||
|
Loading…
x
Reference in New Issue
Block a user