kubernetes-ingress-controller
kubernetes-ingress-controller copied to clipboard
Fix the default name of the pod
What happened
The default pod name created by our helm chart is overly verbose and confusing. It should be shortned to be more clear and guessable.
What you think should happen instead
The current name is ngrok-ingress-controller-kubernetes-ingress-controller-manager for me because it combines the release name and the default name https://github.com/ngrok/kubernetes-ingress-controller/blob/main/helm/ingress-controller/templates/_helpers.tpl#L28
Instead of using the regular name and the chart release name, we should just use the override if provided.
How to reproduce
install the chart and get the pods
This is related to https://github.com/ngrok/kubernetes-ingress-controller/issues/87 since the name is important for your ability to install multiple instances
Current name outcome matrix
| | fullnameOverride | nameOverride | nothing |
|------------------|-------------------------------|----------------------------------------------|----------------------------------------|
| fullnameOverride | fullnameOverride + "-manager" | fullnameOverride | fullnameOverride |
| nameOverride | fullnameOverride + "-manager" | chart.name + "-" + nameOverride + "-manager" | chart.name + nameOverride + "-manager" |
| nothing | fullnameOverride + "-manager" | chart.name + nameOverride + "-manager" | chart.name + "-" + release.name |
for example:
- if
nameOverrideis set to "my-ingress" thenngrok-ingress-controller-my-ingress-manager-58d8dcbbf5-vlxp9is then name - if
fullnameOverrideis to "my-ingress" thenmy-ingress-manager-5865d886d5-x582his the name - if nothing is set set then default name of
ngrok-ingress-controller-kubernetes-ingress-controller-manxzprmis used
@nijikokun the current naming scheme is undesirable to customers. I think it would be advantages to just drop the release.name from the default name all together. What do you think?
- It seems like we are suggesting users to set
release.namewhen installing other controllers leverage the--generate-nameflag, we could leverage this. - Desired state would be getting the name down to
ngrok-ingress-controller-[hash]without the additionalkubernetes-ingress-controllerpart. Even if that means following other ingress controllers suit where they set the chart name to the company name fromkubernetes-ingress-controllertongrok.
This ideally would mean we wouldn't have to change the repository name as well.