[es] Add ingest node support

For #131
This commit is contained in:
Geoff Bourne 2017-03-03 23:35:12 -06:00
parent 07c32d8ee4
commit 55801ac11c
3 changed files with 17 additions and 5 deletions

View file

@ -181,7 +181,8 @@ To simplify all that, this image provides a `TYPE` variable to let you amongst t
* `MASTER` : master-eligible, but holds no data. It is good to have three or more of these in a
large cluster
* `DATA` (or `NON_MASTER`) : holds data and serves search/index requests. Scale these out for elastic-y goodness.
* `GATEWAY` : only operates as a client node or a "smart router". These are the ones whose HTTP port 9200 will need to be exposed
* `GATEWAY` (or `COORDINATING`) : only operates as a client node or a "smart router". These are the ones whose HTTP port 9200 will need to be exposed
* `INGEST` : operates only as an ingest node and is not master or data eligble
A [Docker Compose](https://docs.docker.com/compose/overview/) file will serve as a good example of these three node types:

View file

@ -29,6 +29,13 @@ services:
environment:
TYPE: GATEWAY
UNICAST_HOSTS: master
ingest:
image: itzg/elasticsearch
ports:
- "9222:9200"
environment:
TYPE: INGEST
UNICAST_HOSTS: master
kibana:
image: kibana
ports:

View file

@ -77,15 +77,19 @@ setup_personality() {
if [ -n "$TYPE" ]; then
case $TYPE in
MASTER)
OPTS="$OPTS -E node.master=true -E node.data=false"
OPTS="$OPTS -E node.master=true -E node.data=false -E node.ingest=false"
;;
GATEWAY)
OPTS="$OPTS -E node.master=false -E node.data=false"
GATEWAY|COORDINATING)
OPTS="$OPTS -E node.master=false -E node.data=false -E node.ingest=false"
;;
INGEST)
OPTS="$OPTS -E node.master=false -E node.data=false -E node.ingest=true"
;;
DATA|NON_MASTER)
OPTS="$OPTS -E node.master=false -E node.data=true"
OPTS="$OPTS -E node.master=false -E node.data=true -E node.ingest=false"
;;
*)