-
Notifications
You must be signed in to change notification settings - Fork 490
Kong chart: scope IngressClass controller name by ingress class #1519
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
base: main
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -502,6 +502,7 @@ The name of the Service which will be used by the controller to update the Ingre | |||||||||||||||||||||||||
| {{- $_ := set $autoEnv "CONTROLLER_KONG_ADMIN_TLS_SKIP_VERIFY" true -}} | ||||||||||||||||||||||||||
| {{- $_ := set $autoEnv "CONTROLLER_PUBLISH_SERVICE" ( include "kong.controller-publish-service" . ) -}} | ||||||||||||||||||||||||||
| {{- $_ := set $autoEnv "CONTROLLER_INGRESS_CLASS" .Values.ingressController.ingressClass -}} | ||||||||||||||||||||||||||
| {{- $_ := set $autoEnv "CONTROLLER_GATEWAY_API_CONTROLLER_NAME" (printf "ingress-controllers.konghq.com/-%s" .Values.ingressController.ingressClass) -}} | ||||||||||||||||||||||||||
|
vkobets marked this conversation as resolved.
Outdated
|
||||||||||||||||||||||||||
| {{- $_ := set $autoEnv "CONTROLLER_KONG_ADMIN_TLS_SKIP_VERIFY" true -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_PUBLISH_SERVICE" ( include "kong.controller-publish-service" . ) -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_INGRESS_CLASS" .Values.ingressController.ingressClass -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_GATEWAY_API_CONTROLLER_NAME" (printf "ingress-controllers.konghq.com/-%s" .Values.ingressController.ingressClass) -}} | |
| {{- $gatewayAPIControllerName := "konghq.com/kic-gateway-controller" -}} | |
| {{- if ne .Values.ingressController.ingressClass "kong" -}} | |
| {{- $gatewayAPIControllerName = printf "konghq.com/kic-gateway-controller-%s" .Values.ingressController.ingressClass -}} | |
| {{- end -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_KONG_ADMIN_TLS_SKIP_VERIFY" true -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_PUBLISH_SERVICE" ( include "kong.controller-publish-service" . ) -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_INGRESS_CLASS" .Values.ingressController.ingressClass -}} | |
| {{- $_ := set $autoEnv "CONTROLLER_GATEWAY_API_CONTROLLER_NAME" $gatewayAPIControllerName -}} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -29,5 +29,5 @@ metadata: | |
| labels: | ||
| {{- include "kong.metaLabels" . | nindent 4 }} | ||
| spec: | ||
| controller: ingress-controllers.konghq.com/kong | ||
| controller: ingress-controllers.konghq.com/{{ .Values.ingressController.ingressClass }} | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This change is ok 👍
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. After reading this second time I need to take back my comment: this is not about the ingress class here but about the controller. While we could possibly link these 2 (like you did) I'd prefer not to do this. What I think could be a good way forward and not introducing a breaking change for users is to add a new field in This would also prevent what copilot mentioned about controller being immutable (by setting the default to what was already hardcoded in the template).
Comment on lines
31
to
+32
|
||
| {{- end -}} | ||
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.
This changelog entry describes the alignment change, but it doesn’t call out the operational upgrade impact:
IngressClass.spec.controlleris immutable, so users with an existing chart-managed IngressClass and a non-defaultingressController.ingressClasswill need to delete/recreate the IngressClass before upgrading. Similarly, changing the Gateway API controller name may require updating existing GatewayClasscontrollerNamevalues. Please add explicit upgrade notes here (and ideally in UPGRADE.md) to prevent failed upgrades / unexpected controller non-reconciliation.