Skip to content

Commit

Permalink
Add volume mounting support to helm chart
Browse files Browse the repository at this point in the history
  • Loading branch information
Dean-Coakley authored Mar 12, 2020
1 parent 61f5e25 commit 945bbc7
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 0 deletions.
2 changes: 2 additions & 0 deletions deployments/helm-chart/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,8 @@ Parameter | Description | Default
`controller.terminationGracePeriodSeconds` | The termination grace period of the Ingress controller pod. | 30
`controller.tolerations` | The tolerations of the Ingress controller pods. | []
`controller.affinity` | The affinity of the Ingress controller pods. | {}
`controller.volumes` | The volumes of the Ingress controller pods. | []
`controller.volumeMounts` | The volumeMounts of the Ingress controller pods. | []
`controller.resources` | The resources of the Ingress controller pods. | {}
`controller.replicaCount` | The number of replicas of the Ingress controller deployment. | 1
`controller.ingressClass` | A class of the Ingress controller. The Ingress controller only processes Ingress resources that belong to its class - i.e. have the annotation `"kubernetes.io/ingress.class"` equal to the class. Additionally, the Ingress controller processes Ingress resources that do not have that annotation which can be disabled by setting the "-use-ingress-class-only" flag. | nginx
Expand Down
8 changes: 8 additions & 0 deletions deployments/helm-chart/templates/controller-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ spec:
affinity:
{{ toYaml .Values.controller.affinity | indent 8 }}
{{- end }}
{{- if .Values.controller.volumes }}
volumes:
{{ toYaml .Values.controller.volumes | indent 6 }}
{{- end }}
{{- if .Values.controller.priorityClassName }}
priorityClassName: {{ .Values.controller.priorityClassName }}
{{- end }}
Expand Down Expand Up @@ -69,6 +73,10 @@ spec:
- ALL
add:
- NET_BIND_SERVICE
{{- if .Values.controller.volumeMounts }}
volumeMounts:
{{ toYaml .Values.controller.volumeMounts | indent 8 }}
{{- end }}
env:
- name: POD_NAMESPACE
valueFrom:
Expand Down
8 changes: 8 additions & 0 deletions deployments/helm-chart/templates/controller-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ spec:
affinity:
{{ toYaml .Values.controller.affinity | indent 8 }}
{{- end }}
{{- if .Values.controller.volumes }}
volumes:
{{ toYaml .Values.controller.volumes | indent 6 }}
{{- end }}
{{- if .Values.controller.priorityClassName }}
priorityClassName: {{ .Values.controller.priorityClassName }}
{{- end }}
Expand Down Expand Up @@ -69,6 +73,10 @@ spec:
- ALL
add:
- NET_BIND_SERVICE
{{- if .Values.controller.volumeMounts }}
volumeMounts:
{{ toYaml .Values.controller.volumeMounts | indent 8 }}
{{- end }}
env:
- name: POD_NAMESPACE
valueFrom:
Expand Down
12 changes: 12 additions & 0 deletions deployments/helm-chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,18 @@ controller:
## The affinity of the Ingress controller pods.
affinity: {}

## The volumes of the Ingress controller pods.
volumes: []
# - name: extra-conf
# configMap:
# name: extra-conf

## The volumeMounts of the Ingress controller pods.
volumeMounts: []
# - name: extra-conf
# mountPath: /etc/nginx/conf.d/extra.conf
# subPath: extra.conf

## The number of replicas of the Ingress controller deployment.
replicaCount: 1

Expand Down
6 changes: 6 additions & 0 deletions docs-web/installation/installation-with-helm.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,12 @@ The following tables lists the configurable parameters of the NGINX Ingress cont
* - ``controller.affinity``
- The affinity of the Ingress controller pods.
- {}
* - ``controller.volumes``
- The volumes of the Ingress controller pods.
- []
* - ``controller.volumeMounts``
- The volumeMounts of the Ingress controller pods.
- []
* - ``controller.resources``
- The resources of the Ingress controller pods.
- {}
Expand Down

0 comments on commit 945bbc7

Please sign in to comment.