Skip to content

Commit 812e7ef

Browse files
committed
Helm: add globalConfigurationCustomName parameter
Add globalConfigurationCustomName parameter to controller configuration in helm chart (#6679)
1 parent 5108b30 commit 812e7ef

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

charts/nginx-ingress/templates/_helpers.tpl

+4
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,10 @@ Build the args for the service binary.
291291
- -default-https-listener-port={{ .Values.controller.defaultHTTPSListenerPort}}
292292
{{- if .Values.controller.globalConfiguration.create }}
293293
- -global-configuration=$(POD_NAMESPACE)/{{ include "nginx-ingress.controller.fullname" . }}
294+
{{- else }}
295+
{{- if .Values.controller.globalConfigurationCustomName }}
296+
- -global-configuration={{ .Values.controller.globalConfigurationCustomName }}
297+
{{- end }}
294298
{{- end }}
295299
{{- end }}
296300
- -ready-status={{ .Values.controller.readyStatus.enable }}

charts/nginx-ingress/values.schema.json

+8
Original file line numberDiff line numberDiff line change
@@ -1042,6 +1042,14 @@
10421042
}
10431043
]
10441044
},
1045+
"globalConfigurationCustomName": {
1046+
"type": "string",
1047+
"default": "",
1048+
"title": "The globalConfigurationCustomName",
1049+
"examples": [
1050+
"the-namespace/the-name-of-the-global-configuration-custom-resource"
1051+
]
1052+
},
10451053
"enableSnippets": {
10461054
"type": "boolean",
10471055
"default": false,

charts/nginx-ingress/values.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -372,6 +372,10 @@ controller:
372372
# port: 5353
373373
# protocol: TCP
374374

375+
## globalConfigurationCustomName: "the-namespace/the-name-of-the-global-configuration-custom-resource"
376+
## The name of the GlobalConfiguration custom resource to use instead of the one provided by default when controller.globalConfiguration.create is set to false.
377+
## See: https://github.com/nginxinc/kubernetes-ingress/tree/v3.6.2/examples/custom-resources/custom-listeners#prerequisites
378+
375379
## Enable custom NGINX configuration snippets in Ingress, VirtualServer, VirtualServerRoute and TransportServer resources.
376380
enableSnippets: false
377381

0 commit comments

Comments
 (0)