From 6baff8e72dd1ded0eee5024a47354f32e3df0857 Mon Sep 17 00:00:00 2001 From: Dmitry Kalashnik Date: Thu, 23 May 2019 16:38:22 +0400 Subject: [PATCH 1/1] Use local elasticsearch instance as url instead of VIP Change-Id: I6584b9cfc5b3718f3879ecfe49cbfdbc222b8d1d Closes-bug: PROD-30529 (cherry picked from commit ac984718ff61fc2d2e7a63844ac9d3b7c0dc8dd3) --- elasticsearch/meta/salt.yml | 4 ++-- tests/pillar/client.sls | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/elasticsearch/meta/salt.yml b/elasticsearch/meta/salt.yml index a34e0db..3d2bdb1 100644 --- a/elasticsearch/meta/salt.yml +++ b/elasticsearch/meta/salt.yml @@ -1,7 +1,7 @@ minion: {%- if pillar.get('elasticsearch', {}).get('client') %} elasticsearch: - {%- from "elasticsearch/map.jinja" import client with context %} + {%- from "elasticsearch/map.jinja" import server with context %} elasticsearch: - host: {{ client.server.get("scheme", "http") }}://{{client.server.host}}:{{client.server.port}} + host: {{ server.bind.address }}:{{ server.bind.port }} {%- endif %} diff --git a/tests/pillar/client.sls b/tests/pillar/client.sls index 216b590..8b8ef75 100644 --- a/tests/pillar/client.sls +++ b/tests/pillar/client.sls @@ -5,3 +5,8 @@ elasticsearch: server: host: elasticsearch.host port: 9200 + server: + enabled: false + bind: + address: 127.0.0.1 + port: 9200 -- 2.32.7