Skip to content
This repository was archived by the owner on May 16, 2023. It is now read-only.

Disabling deprecation logs to be indexed#1472

Closed
framsouza wants to merge 1 commit intoelastic:7.xfrom
framsouza:master-only-fix
Closed

Disabling deprecation logs to be indexed#1472
framsouza wants to merge 1 commit intoelastic:7.xfrom
framsouza:master-only-fix

Conversation

@framsouza
Copy link
Copy Markdown
Contributor

Fix #1462

Copy link
Copy Markdown

@mark-vieira mark-vieira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but looks like this is causing some unit tests to fail due to the new default entry in elasticsearch.yml.

Copy link
Copy Markdown
Member

@jmlrt jmlrt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@framsouza I think you need to rebase your branch to 7.x upstream as there is a failing tests on K8S 1.18 in https://devops-ci.elastic.co/job/elastic+helm-charts+pull-request+cluster-creation/1626/KUBERNETES_VERSION=1.18,label=docker&&virtual/ but 1.18 CI test has been removed 2 months ago in 75a06f9#diff-3253477baaea5115041883346a02c3aeb58a2b622d803b5ebd650c489d7c3f14

Copy link
Copy Markdown
Member

@jmlrt jmlrt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As esConfig.elasticsearch.yml value is overriding the default config files in the container, we always need to answer it contains everything required.

Comment thread elasticsearch/values.yaml
Comment on lines +26 to +27
elasticsearch.yml: |
cluster.deprecation_indexing.enabled: false
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this will override the default elasticsearch.yml from the Docker image, we need to include cluster_name and network_host.

Suggested change
elasticsearch.yml: |
cluster.deprecation_indexing.enabled: false
elasticsearch.yml: |
cluster.name: "docker-cluster"
network.host: 0.0.0.0
# required for https://github.com/elastic/helm-charts/issues/1462
cluster.deprecation_indexing.enabled: false

@jmlrt
Copy link
Copy Markdown
Member

jmlrt commented Dec 13, 2021

another way could be to include an environment variables in

env:
- name: node.name
valueFrom:
fieldRef:
fieldPath: metadata.name
{{- if has "master" .Values.roles }}
- name: cluster.initial_master_nodes
value: "{{ template "elasticsearch.endpoints" . }}"
{{- end }}
- name: node.roles
value: "{{ template "elasticsearch.roles" . }}"
{{- if lt (int (include "elasticsearch.esMajorVersion" .)) 7 }}
- name: discovery.zen.ping.unicast.hosts
value: "{{ template "elasticsearch.masterService" . }}-headless"
{{- else }}
- name: discovery.seed_hosts
value: "{{ template "elasticsearch.masterService" . }}-headless"
{{- end }}
- name: cluster.name
value: "{{ .Values.clusterName }}"
- name: network.host
value: "{{ .Values.networkHost }}"
{{- if .Values.secret.enabled }}
- name: ELASTIC_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "elasticsearch.uname" . }}-credentials
key: password
{{- end }}
{{- if .Values.esJavaOpts }}
- name: ES_JAVA_OPTS
value: "{{ .Values.esJavaOpts }}"
{{- end }}
as it doesn't impact the `elasticsearch.yaml.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants