Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions charts/nginx-ingress/templates/controller-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ spec:
targetPort: {{ .Values.controller.service.httpPort.targetPort }}
protocol: TCP
name: {{ .Values.controller.service.httpPort.name }}
{{- if or (eq .Values.controller.service.type "LoadBalancer") (eq .Values.controller.service.type "NodePort") }}
{{- if or (eq .Values.controller.service.type "NodePort") (and (eq .Values.controller.service.type "LoadBalancer") (ternary .Values.controller.service.allocateLoadBalancerNodePorts true (hasKey .Values.controller.service "allocateLoadBalancerNodePorts"))) }}
nodePort: {{ .Values.controller.service.httpPort.nodePort }}
{{- end }}
{{- end }}
Expand All @@ -63,7 +63,7 @@ spec:
targetPort: {{ .Values.controller.service.httpsPort.targetPort }}
protocol: TCP
name: {{ .Values.controller.service.httpsPort.name }}
{{- if or (eq .Values.controller.service.type "LoadBalancer") (eq .Values.controller.service.type "NodePort") }}
{{- if or (eq .Values.controller.service.type "NodePort") (and (eq .Values.controller.service.type "LoadBalancer") (ternary .Values.controller.service.allocateLoadBalancerNodePorts true (hasKey .Values.controller.service "allocateLoadBalancerNodePorts"))) }}
nodePort: {{ .Values.controller.service.httpsPort.nodePort }}
{{- end }}
{{- end }}
Expand Down
2 changes: 1 addition & 1 deletion charts/nginx-ingress/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1443,7 +1443,7 @@
]
},
"allocateLoadBalancerNodePorts": {
"default": false,
"default": true,
"title": "The allocateLoadBalancerNodePorts Schema",
"$ref": "https://raw.githubusercontent.com/nginxinc/kubernetes-json-schema/master/v1.35.1/_definitions.json#/definitions/io.k8s.api.core.v1.ServiceSpec/properties/allocateLoadBalancerNodePorts"
},
Expand Down
2 changes: 1 addition & 1 deletion charts/nginx-ingress/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -518,7 +518,7 @@ controller:
loadBalancerSourceRanges: []

## Whether to automatically allocate NodePorts (only for LoadBalancers).
# allocateLoadBalancerNodePorts: false
# allocateLoadBalancerNodePorts: true

## Dual stack preference.
## Valid values: SingleStack, PreferDualStack, RequireDualStack
Expand Down
Loading