From 32a259cd4544ad332f448f861ebbc8d2bdb34fbf Mon Sep 17 00:00:00 2001 From: Arpit Agarwal <15676216+arpitjindal97@users.noreply.github.com> Date: Wed, 7 Sep 2022 13:03:57 +0200 Subject: [PATCH] [bitnami/elasticsearch] Ability to add extraHosts (#12145) Signed-off-by: Arpit Agarwal Signed-off-by: Arpit Agarwal --- bitnami/elasticsearch/Chart.yaml | 2 +- bitnami/elasticsearch/README.md | 3 ++- bitnami/elasticsearch/templates/_helpers.tpl | 3 +++ bitnami/elasticsearch/values.yaml | 6 ++++++ 4 files changed, 12 insertions(+), 2 deletions(-) diff --git a/bitnami/elasticsearch/Chart.yaml b/bitnami/elasticsearch/Chart.yaml index 3e6b5212a7..c9a23c70bb 100644 --- a/bitnami/elasticsearch/Chart.yaml +++ b/bitnami/elasticsearch/Chart.yaml @@ -25,4 +25,4 @@ name: elasticsearch sources: - https://github.com/bitnami/containers/tree/main/bitnami/elasticsearch - https://www.elastic.co/products/elasticsearch -version: 19.2.5 +version: 19.3.0 diff --git a/bitnami/elasticsearch/README.md b/bitnami/elasticsearch/README.md index f289f1edc9..df63298df2 100644 --- a/bitnami/elasticsearch/README.md +++ b/bitnami/elasticsearch/README.md @@ -96,6 +96,7 @@ $ helm delete --purge my-release | `snapshotRepoPath` | File System snapshot repository path | `""` | | `config` | Override elasticsearch configuration | `{}` | | `extraConfig` | Append extra configuration to the elasticsearch node configuration | `{}` | +| `extraHosts` | A list of external hosts which are part of this cluster | `[]` | | `extraVolumes` | A list of volumes to be added to the pod | `[]` | | `extraVolumeMounts` | A list of volume mounts to be added to the pod | `[]` | | `initScripts` | Dictionary of init scripts. Evaluated as a template. | `{}` | @@ -971,4 +972,4 @@ Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and -limitations under the License. \ No newline at end of file +limitations under the License. diff --git a/bitnami/elasticsearch/templates/_helpers.tpl b/bitnami/elasticsearch/templates/_helpers.tpl index b660ca5994..5ec2af68e1 100644 --- a/bitnami/elasticsearch/templates/_helpers.tpl +++ b/bitnami/elasticsearch/templates/_helpers.tpl @@ -189,6 +189,9 @@ Return the hostname of every ElasticSearch seed node {{- $ingestFullname := (printf "%s-hl" (include "elasticsearch.ingest.fullname" .) | trunc 63 | trimSuffix "-") }} {{- $ingestFullname }}.{{ $releaseNamespace }}.svc.{{ $clusterDomain }}, {{- end -}} +{{- range .Values.extraHosts }} +{{- . }}, +{{- end }} {{- end -}} {{/* diff --git a/bitnami/elasticsearch/values.yaml b/bitnami/elasticsearch/values.yaml index 107044a941..08be15fabe 100644 --- a/bitnami/elasticsearch/values.yaml +++ b/bitnami/elasticsearch/values.yaml @@ -99,6 +99,12 @@ config: {} ## ref: https://www.elastic.co/guide/en/elasticsearch/reference/current/settings.html ## extraConfig: {} +## @param extraHosts A list of external hosts which are part of this cluster +## Example Use Case: When you have a cluster with nodes spaned acorss multiple K8s or namespaces +## extraHosts: +## - datacenter2-elasticsearch-master-hl.namespace2.svc +## - datacenter2-elasticsearch-data-hl.namespace2.svc +extraHosts: [] ## @param extraVolumes A list of volumes to be added to the pod ## Example Use Case: mount ssl certificates when elasticsearch has tls enabled ## extraVolumes: