-
Notifications
You must be signed in to change notification settings - Fork 16.7k
[stable/sonarqube] allow overriding app fullname #20561
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: usmonster The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Hi @usmonster. Thanks for your PR. I'm waiting for a helm member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Signed-off-by: Usman Akeju <akeju00+github@gmail.com>
83a59fd
to
4cac4a0
Compare
/assign @rjkernick |
{{- $name := default .Chart.Name .Values.nameOverride -}} | ||
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} | ||
{{- if .Values.fullnameOverride -}} | ||
{{- printf "%s" .Values.fullnameOverride | trunc 63 -}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess I could get rid of the printf
here...
/ok-to-test |
Signed-off-by: Usman Akeju <akeju00+github@gmail.com>
Ping @rjkernick for lgtm/approval 🙏 |
This chart has been deprecated and moved: #21007 |
Is this a new chart
No.
What this PR does / why we need it:
Allows to override the
fullname
used in various places. Today, a helper template function determines the format of the name, and it can't be overridden. This is inconvenient and unwanted in many cases (e.g. when tooling maps the app name to a hostname—I wantsonarqube.example.org
, but today I can only getsonarqube-sonarqube.example.org
). It's generally better to allow the fullname to be explicitly overridden if so desired.Special notes for your reviewer:
This has a similar, but subtly different effect as adding the
nameOverride
value. I hesitated to instead implement behavior that would reusename
as thefullname
(e.g. introduce auseNameAsFullname
boolean value), but I decided on an approach that allows these values to be overridden independently.Also, since the
nameOverride
is already undocumented (I assume intentionally?), I likewise opted to leave this new value undocumented.Checklist
Variables are documented in the README.md[stable/mychartname]
)