Skip to content

Commit

Permalink
Make http/https targetPort configurable in charts
Browse files Browse the repository at this point in the history
  • Loading branch information
Raul Marrero authored and Rulox committed May 14, 2019
1 parent fd95a16 commit 0c4f20b
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion deployments/helm-chart/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: nginx-ingress
version: 0.8.0
version: 0.9.0
appVersion: edge
description: NGINX Ingress Controller
icon: https://raw.githubusercontent.com/nginxinc/kubernetes-ingress/master/deployments/helm-chart/chart-icon.png
Expand Down
2 changes: 2 additions & 0 deletions deployments/helm-chart/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,11 @@ Parameter | Description | Default
`controller.service.httpPort.enable` | Enables the HTTP port for the Ingress controller service. | true
`controller.service.httpPort.port` | The HTTP port of the Ingress controller service. | 80
`controller.service.httpPort.nodePort` | The custom NodePort for the HTTP port. Requires `controller.service.type` set to `NodePort`. | ""
`controller.service.httpPort.targetPort` | The target port of the HTTP port of the Ingress controller service. | 80
`controller.service.httpsPort.enable` | Enables the HTTPS port for the Ingress controller service. | true
`controller.service.httpsPort.port` | The HTTPS port of the Ingress controller service. | 443
`controller.service.httpsPort.nodePort` | The custom NodePort for the HTTPS port. Requires `controller.service.type` set to `NodePort`. | ""
`controller.service.httpsPort.targetPort` | The target port of the HTTPS port of the Ingress controller service. | 443
`controller.serviceAccount.name` | The name of the service account of the Ingress controller pods. Used for RBAC. | Autogenerated
`controller.serviceAccount.imagePullSecrets` | The names of the secrets containing docker registry credentials. | []
`controller.reportIngressStatus.enable` | Update the address field in the status of Ingresses resources with an external address of the Ingress controller. You must also specify the source of the external address either through an external service via `controller.reportIngressStatus.externalService` or the `external-status-address` entry in the ConfigMap via `controller.config.entries`. **Note:** `controller.config.entries.external-status-address` takes precedence if both are set. | true
Expand Down
4 changes: 2 additions & 2 deletions deployments/helm-chart/templates/controller-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ spec:
ports:
{{- if .Values.controller.service.httpPort.enable }}
- port: {{ .Values.controller.service.httpPort.port }}
targetPort: 80
targetPort: {{ .Values.controller.service.httpPort.targetPort }}
protocol: TCP
name: http
{{- if eq .Values.controller.service.type "NodePort" }}
Expand All @@ -38,7 +38,7 @@ spec:
{{- end }}
{{- if .Values.controller.service.httpsPort.enable }}
- port: {{ .Values.controller.service.httpsPort.port }}
targetPort: 443
targetPort: {{ .Values.controller.service.httpsPort.targetPort }}
protocol: TCP
name: https
{{- if eq .Values.controller.service.type "NodePort" }}
Expand Down
6 changes: 6 additions & 0 deletions deployments/helm-chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,9 @@ controller:
## The custom NodePort for the HTTP port. Requires controller.service.type set to NodePort.
nodePort: ""

## The HTTP port on the POD where the Ingress controller service is running.
targetPort: 80

httpsPort:
## Enables the HTTPS port for the Ingress controller service.
enable: true
Expand All @@ -151,6 +154,9 @@ controller:
## The custom NodePort for the HTTPS port. Requires controller.service.type set to NodePort.
nodePort: ""

## The HTTPS port on the POD where the Ingress controller service is running.
targetPort: 443

serviceAccount:
## The name of the service account of the Ingress controller pods. Used for RBAC.
## Autogenerated if not set or set to "".
Expand Down

0 comments on commit 0c4f20b

Please sign in to comment.