mirror of
https://github.com/TECHNOFAB11/zfs-localpv.git
synced 2026-02-02 15:45:13 +01:00
add support for providing additional volumes and adding init containers
Signed-off-by: Jesse Nelson <jesse@swirldslabs.com> Signed-off-by: Niladri Halder <niladri.halder26@gmail.com>
This commit is contained in:
parent
35e06fdc53
commit
347d92a16f
3 changed files with 27 additions and 0 deletions
1
changelogs/unreleased/454-jnels124.md
Normal file
1
changelogs/unreleased/454-jnels124.md
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
add support to deployment yaml to allower user to specify additional volumes and init containers
|
||||||
|
|
@ -38,6 +38,13 @@ spec:
|
||||||
priorityClassName: {{ template "zfslocalpv.zfsController.priorityClassName" . }}
|
priorityClassName: {{ template "zfslocalpv.zfsController.priorityClassName" . }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
serviceAccount: {{ .Values.serviceAccount.zfsController.name }}
|
serviceAccount: {{ .Values.serviceAccount.zfsController.name }}
|
||||||
|
{{- if .Values.zfsController.initContainers }}
|
||||||
|
initContainers:
|
||||||
|
{{- range $key, $value := .Values.zfsController.initContainers }}
|
||||||
|
- name: {{ $key }}
|
||||||
|
{{ toYaml $value | indent 10 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
containers:
|
containers:
|
||||||
- name: {{ .Values.zfsController.resizer.name }}
|
- name: {{ .Values.zfsController.resizer.name }}
|
||||||
image: "{{ .Values.zfsController.resizer.image.registry }}{{ .Values.zfsController.resizer.image.repository }}:{{ .Values.zfsController.resizer.image.tag }}"
|
image: "{{ .Values.zfsController.resizer.image.registry }}{{ .Values.zfsController.resizer.image.repository }}:{{ .Values.zfsController.resizer.image.tag }}"
|
||||||
|
|
@ -121,6 +128,12 @@ spec:
|
||||||
volumes:
|
volumes:
|
||||||
- name: socket-dir
|
- name: socket-dir
|
||||||
emptyDir: {}
|
emptyDir: {}
|
||||||
|
{{- if .Values.zfsController.additionalVolumes }}
|
||||||
|
{{- range $name, $config := .Values.zfsController.additionalVolumes }}
|
||||||
|
- name: {{ $name }}
|
||||||
|
{{- tpl (toYaml $config) $ | nindent 10 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.imagePullSecrets }}
|
{{- if .Values.imagePullSecrets }}
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
{{ toYaml .Values.imagePullSecrets | indent 2 }}
|
{{ toYaml .Values.imagePullSecrets | indent 2 }}
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,13 @@ spec:
|
||||||
{{- end }}
|
{{- end }}
|
||||||
serviceAccount: {{ .Values.serviceAccount.zfsNode.name }}
|
serviceAccount: {{ .Values.serviceAccount.zfsNode.name }}
|
||||||
hostNetwork: true
|
hostNetwork: true
|
||||||
|
{{- if .Values.zfsNode.initContainers }}
|
||||||
|
initContainers:
|
||||||
|
{{- range $key, $value := .Values.zfsNode.initContainers }}
|
||||||
|
- name: {{ $key }}
|
||||||
|
{{ toYaml $value | indent 10 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
containers:
|
containers:
|
||||||
- name: {{ .Values.zfsNode.driverRegistrar.name }}
|
- name: {{ .Values.zfsNode.driverRegistrar.name }}
|
||||||
image: "{{ .Values.zfsNode.driverRegistrar.image.registry }}{{ .Values.zfsNode.driverRegistrar.image.repository }}:{{ .Values.zfsNode.driverRegistrar.image.tag }}"
|
image: "{{ .Values.zfsNode.driverRegistrar.image.registry }}{{ .Values.zfsNode.driverRegistrar.image.repository }}:{{ .Values.zfsNode.driverRegistrar.image.tag }}"
|
||||||
|
|
@ -132,6 +139,12 @@ spec:
|
||||||
hostPath:
|
hostPath:
|
||||||
path: {{ .Values.zfsNode.kubeletDir }}
|
path: {{ .Values.zfsNode.kubeletDir }}
|
||||||
type: Directory
|
type: Directory
|
||||||
|
{{- if .Values.zfsNode.additionalVolumes }}
|
||||||
|
{{- range $name, $config := .Values.zfsNode.additionalVolumes }}
|
||||||
|
- name: {{ $name }}
|
||||||
|
{{- tpl (toYaml $config) $ | nindent 10 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
{{- if .Values.imagePullSecrets }}
|
{{- if .Values.imagePullSecrets }}
|
||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
{{ toYaml .Values.imagePullSecrets | indent 2 }}
|
{{ toYaml .Values.imagePullSecrets | indent 2 }}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue