diff --git a/csi-driver-templates/templates/pods/_quobyte_csi_controller_pod.tpl b/csi-driver-templates/templates/pods/_quobyte_csi_controller_pod.tpl index d98e354..6c35809 100644 --- a/csi-driver-templates/templates/pods/_quobyte_csi_controller_pod.tpl +++ b/csi-driver-templates/templates/pods/_quobyte_csi_controller_pod.tpl @@ -26,9 +26,9 @@ spec: app: quobyte-csi-controller-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} role: quobyte-csi-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} spec: - {{- if default "" .Values.quobyte.csiDriverNodeSelector | trim }} + {{- if .Values.quobyte.csiControllerNodeSelector }} nodeSelector: - {{ .Values.quobyte.csiDriverNodeSelector | trim }} + {{- .Values.quobyte.csiControllerNodeSelector | toYaml | nindent 8 }} {{- end }} priorityClassName: system-cluster-critical serviceAccount: quobyte-csi-controller-sa-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} diff --git a/csi-driver-templates/templates/pods/_quobyte_csi_node_driver_pod.tpl b/csi-driver-templates/templates/pods/_quobyte_csi_node_driver_pod.tpl index 5b4a0b2..bab9e9f 100644 --- a/csi-driver-templates/templates/pods/_quobyte_csi_node_driver_pod.tpl +++ b/csi-driver-templates/templates/pods/_quobyte_csi_node_driver_pod.tpl @@ -19,9 +19,9 @@ spec: app: quobyte-csi-node-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} role: quobyte-csi spec: - {{- if default "" .Values.quobyte.csiDriverNodeSelector | trim }} + {{- if .Values.quobyte.csiDriverNodeSelector }} nodeSelector: - {{ .Values.quobyte.csiDriverNodeSelector | trim }} + {{- .Values.quobyte.csiDriverNodeSelector | toYaml | nindent 8 }} {{- end }} priorityClassName: system-node-critical serviceAccount: quobyte-csi-node-sa-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} diff --git a/csi-driver-templates/templates/pods/_quobyte_csi_pod_killer_cache.tpl b/csi-driver-templates/templates/pods/_quobyte_csi_pod_killer_cache.tpl index 16a94c6..6a420ef 100644 --- a/csi-driver-templates/templates/pods/_quobyte_csi_pod_killer_cache.tpl +++ b/csi-driver-templates/templates/pods/_quobyte_csi_pod_killer_cache.tpl @@ -21,9 +21,9 @@ spec: app: quobyte-csi-pod-killer-cache-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} role: quobyte-csi-pod-killer-cache-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} spec: - {{- if default "" .Values.quobyte.podKillerCacheNodeSelector | trim }} + {{- if .Values.quobyte.podKiller.nodeSelector }} nodeSelector: - {{ .Values.quobyte.podKillerCacheNodeSelector | trim }} + {{- .Values.quobyte.podKiller.nodeSelector | toYaml | nindent 8 }} {{- end }} priorityClassName: system-cluster-critical serviceAccount: quobyte-csi-pod-killer-cache-sa-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} @@ -37,7 +37,7 @@ spec: apiVersion: v1 kind: Service metadata: - name: quobyte-pod-killer-cache + name: quobyte-pod-killer-cache-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }} namespace: kube-system spec: selector: diff --git a/csi-driver-templates/templates/pods/containers/_quobyte_pod_mount_monitor_container.tpl b/csi-driver-templates/templates/pods/containers/_quobyte_pod_mount_monitor_container.tpl index 4a77caa..1c69b63 100644 --- a/csi-driver-templates/templates/pods/containers/_quobyte_pod_mount_monitor_container.tpl +++ b/csi-driver-templates/templates/pods/containers/_quobyte_pod_mount_monitor_container.tpl @@ -14,7 +14,7 @@ args: - "--node_name=$(KUBE_NODE_NAME)" - "--driver_name={{ .Values.quobyte.csiProvisionerName }}" - - "--service_url=http://quobyte-pod-killer-cache.$(NAMESPACE).svc.cluster.local:80/" + - "--service_url=http://quobyte-pod-killer-cache-{{ .Values.quobyte.csiProvisionerName | replace "." "-" }}.$(NAMESPACE).svc.cluster.local:80/" - "--monitoring_interval={{ .Values.quobyte.podKiller.monitoringInterval }}" - "--role=monitor" env: diff --git a/csi-driver-templates/values.yaml b/csi-driver-templates/values.yaml index 59ef162..de84ab2 100644 --- a/csi-driver-templates/values.yaml +++ b/csi-driver-templates/values.yaml @@ -75,11 +75,12 @@ quobyte: # Empty means all the nodes in the k8s cluster i.e. no node selector will be used. # nodeSelector: ": ''" # Example: csiDriverNodeSelector: "quobyteCsiDriverNode: 'true'" - csiDriverNodeSelector: "" - # Pod killer cache node selector - leaving it empty creates pod killer cache pod + csiDriverNodeSelector: {} + # CSI controller node selector - leaving it empty creates CSI controller pod # on any of the k8s node - # Example: podKillerCacheNodeSelector: "quobytePodCacheNode: 'true'" - podKillerCacheNodeSelector: "" + # nodeSelector object of form: : '' + csiControllerNodeSelector: {} + podKiller: # To disable pod killer, uninstall current CSI driver (helm uninstall ) # set enable: false and install CSI driver again @@ -94,6 +95,7 @@ quobyte: # pod killer pod so that the cache endpoint is resolved. # See https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy dnsPolicy: "" + nodeSelector: {} # The dev configuration is intended for Quobyte Developers and internal use. # Please do NOT change the dev: configuration unless otherwise advised to change.