Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

helm-chart: minor refactoring of syntax #1419

Merged
merged 2 commits into from
Oct 11, 2021

Conversation

consideRatio
Copy link
Member

  • helm-chart: consistent use of with
  • helm-chart: don't use trimSuffix after toYaml, not needed

@consideRatio consideRatio mentioned this pull request Oct 10, 2021
23 tasks
@consideRatio consideRatio added code:helm-chart Helm template changes. maintenance Under the hood improvements and fixes labels Oct 10, 2021
Comment on lines -15 to 17
{{- range $key, $value := .Values.ingress.annotations }}
{{ $key }}: {{ $value | quote }}
{{- with .Values.ingress.annotations }}
{{- . | toYaml | nindent 4 }}
{{- end }}
Copy link
Member Author

Choose a reason for hiding this comment

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

The old pattern has been useful in the past to enforce passed values are strings, but we now have a schema to force users to make their annotations strings in the first place - so we can now use toYaml without additional interventions.

{{- end }}
{{- end }}
spec:
{{- with .Values.ingress.ingressClassName }}
ingressClassName: "{{ . }}"
ingressClassName: {{ . | quote }}
Copy link
Member Author

Choose a reason for hiding this comment

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

I don't care much about this, I just wanted consistency within this file.

@minrk minrk merged commit f8a9d7a into jupyterhub:master Oct 11, 2021
consideRatio pushed a commit to jupyterhub/helm-chart that referenced this pull request Oct 11, 2021
jupyterhub/binderhub#1419 Merge pull request #1419 from consideRatio/pr/refactor-templates
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code:helm-chart Helm template changes. maintenance Under the hood improvements and fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants