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

Fix formatting issue in values.yaml#1042

Closed
fmd wants to merge 1 commit intoelastic:masterfrom
fmd:patch-1
Closed

Fix formatting issue in values.yaml#1042
fmd wants to merge 1 commit intoelastic:masterfrom
fmd:patch-1

Conversation

@fmd
Copy link
Copy Markdown

@fmd fmd commented Feb 3, 2021

The template looks like this:

{{- range .Values.ingress.hosts }}
    {{- if $ingressPath }}
    - host: {{ . }}
      http:
        paths:
          - path: {{ $ingressPath }}
            backend:
              serviceName: {{ $fullName }}
              servicePort: {{ $httpPort }}

where $ingressPath is .Values.ingress.path

This means that following the format in the values.yaml doesn't work. Assuming that the template is correct, this is the fix (it works for us)

  • Chart version not bumped (the versions are all bumped and released at the same time)
  • README.md updated with any new values or changes
  • Updated template tests in ${CHART}/tests/*.py
  • Updated integration tests in ${CHART}/examples/*/test/goss.yaml

The template looks like this:

```
{{- range .Values.ingress.hosts }}
    {{- if $ingressPath }}
    - host: {{ . }}
      http:
        paths:
          - path: {{ $ingressPath }}
            backend:
              serviceName: {{ $fullName }}
              servicePort: {{ $httpPort }}
```

where `$ingressPath` is `.Values.ingress.path`

This means that following the format in the `values.yaml` doesn't work. Assuming that the template is correct, this is the fix (it works for us)
@elasticmachine
Copy link
Copy Markdown
Collaborator

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

@cla-checker-service
Copy link
Copy Markdown

cla-checker-service Bot commented Feb 3, 2021

💚 CLA has been signed

@jmlrt
Copy link
Copy Markdown
Member

jmlrt commented Feb 3, 2021

Hi @fmd,
Flexible ingress have been added in #994 and using $ingressPath is now the deprecated way that we kept only for backward compatibility.

You can see in the ingress template code that $ingressPath is only used when .Values.ingress.path exist, otherwise it use the new way:

{{- if $ingressPath }}
- host: {{ . }}
http:
paths:
- path: {{ $ingressPath }}
backend:
serviceName: {{ $fullName }}
servicePort: {{ $httpPort }}
{{- else }}
- host: {{ .host }}
http:
paths:
{{- range .paths }}
- path: {{ .path }}
backend:
serviceName: {{ $fullName }}
servicePort: {{ .servicePort | default $httpPort }}
{{- end }}
{{- end }}

@jmlrt jmlrt added elasticsearch won't fix This will not be worked on labels Feb 3, 2021
@jmlrt jmlrt closed this Mar 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

elasticsearch won't fix This will not be worked on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants