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

fix(redis): Remove fullnameOverride from redis #120

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mjasion
Copy link
Contributor

@mjasion mjasion commented Jul 13, 2023

Waits for #21

Copying @omesser comment from #123

I recommend the approach where for such things we provide a full name override but the default behavior is to calculate the name in the chart, so the fullnameOverride value is either commented out (@jesper7 will hate it) or just empty string.

We can create a helper template (in _helpers.tpl) along those lines:

{{- define "studio.rayOperator.fullname" -}}
{{- if .Values.rayOperator.fullnameOverride -}}
{{- .Values.rayOperator.fullnameOverride | trunc 63 | trimSuffix "-" -}}
{{- else -}}
{{- printf "%s-ray-operator" .Release.Name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{- end -}}

and use in values via {{ include "studio.rayOperator.fullname" . }}

Whenever we have such if-else boilerplate to calc a name or field - we can move it to a helper value to keep the resource charts clean and we would probably end up reusing a lot of those.

don't have a strong opinion about ray vs rayOperator but since the actual ray cluster is a CRD and not the operator that's installed in the chart it might be less confusing to make the distinction obvious via naming, harming brevity

@mjasion mjasion requested a review from jesper7 July 13, 2023 15:17
@mjasion mjasion self-assigned this Jul 13, 2023
@mjasion mjasion marked this pull request as draft July 13, 2023 15:18
@shcheklein
Copy link
Member

@mjasion is still relevant?

@0x2b3bfa0 0x2b3bfa0 assigned 0x2b3bfa0 and unassigned mjasion Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants