From: Guillaume Thouvenin Date: Thu, 20 Oct 2016 12:52:25 +0000 (+0200) Subject: Use 'network.host' to set 'bind_host' X-Git-Tag: 2016.12~5^2~15^2~3 X-Git-Url: https://gerrit.mcp.mirantis.com/gitweb?p=salt-formulas%2Felasticsearch.git;a=commitdiff_plain;h=fc18d8c2f7e60e9737addef93b4520d2bdd8e300;ds=inline Use 'network.host' to set 'bind_host' --- diff --git a/elasticsearch/files/elasticsearch.yml b/elasticsearch/files/elasticsearch.yml index 7d2a04f..5031bb1 100644 --- a/elasticsearch/files/elasticsearch.yml +++ b/elasticsearch/files/elasticsearch.yml @@ -212,22 +212,21 @@ bootstrap.mlockall: {{ server.mlockall|lower }} # communication. (the range means that if the port is busy, it will automatically # try the next port). -# Set the bind address specifically (IPv4 or IPv6): -# -# -network.bind_host: {{ server.bind.address }} -http.port: {{ server.bind.port }} -http.enabled: true -# Set the address other nodes will use to communicate with this node. If not -# set, it is automatically derived. It must point to an actual IP address. +# Set both 'bind_host' and 'publish_host': # +# network.host: 192.168.0.1 + +{%- if server.get('bind', {}).address is defined %} +network.host: {{ server.bind.address }} +{%- endif %} + +# Set specifically the address other nodes will use to communicate with this +# node. If not set, it is automatically derived. It must point to an actual +# IP address. {%- if server.publish_host is defined %} network.publish_host: {{ server.publish_host }} {%- endif %} -# Set both 'bind_host' and 'publish_host': -# -# network.host: 192.168.0.1 # Set a custom port for the node to node communication (9300 by default): # @@ -240,6 +239,9 @@ network.publish_host: {{ server.publish_host }} # Set a custom port to listen for HTTP traffic: # # http.port: 9200 +{%- if server.get('bind', {}).port is defined %} +http.port: {{ server.bind.port }} +{%- endif %} # Set a custom allowed content length: # @@ -248,6 +250,7 @@ network.publish_host: {{ server.publish_host }} # Disable HTTP completely: # # http.enabled: false +http.enabled: true ################################### Gateway ###################################