diff --git a/stable/democratic-csi/Chart.yaml b/stable/democratic-csi/Chart.yaml index 9b81d48..0975558 100644 --- a/stable/democratic-csi/Chart.yaml +++ b/stable/democratic-csi/Chart.yaml @@ -2,4 +2,4 @@ apiVersion: v1 appVersion: "1.0" description: csi storage for container orchestration systems name: democratic-csi -version: 0.13.0 +version: 0.13.1 diff --git a/stable/democratic-csi/templates/_helpers.tpl b/stable/democratic-csi/templates/_helpers.tpl index e1cc081..db5ee4e 100644 --- a/stable/democratic-csi/templates/_helpers.tpl +++ b/stable/democratic-csi/templates/_helpers.tpl @@ -54,6 +54,10 @@ Create chart name and version as used by the chart label. {{- end }} {{- range .Values.controller.externalAttacher.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.controller.externalAttacher.resources }} + resources: +{{ toYaml .Values.controller.externalAttacher.resources | indent 4 }} {{- end }} {{- if eq $windows "0" }} volumeMounts: @@ -77,6 +81,10 @@ Create chart name and version as used by the chart label. {{- end }} {{- range .Values.controller.externalProvisioner.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.controller.externalProvisioner.resources }} + resources: +{{ toYaml .Values.controller.externalProvisioner.resources | indent 4 }} {{- end }} {{- if eq $windows "0" }} volumeMounts: @@ -116,6 +124,10 @@ Create chart name and version as used by the chart label. {{- end }} {{- range .Values.controller.externalResizer.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.controller.externalResizer.resources }} + resources: +{{ toYaml .Values.controller.externalResizer.resources | indent 4 }} {{- end }} {{- if eq $windows "0" }} volumeMounts: @@ -158,6 +170,10 @@ Create chart name and version as used by the chart label. {{- end }} {{- range .Values.controller.externalSnapshotter.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.controller.externalSnapshotter.resources }} + resources: +{{ toYaml .Values.controller.externalSnapshotter.resources | indent 4 }} {{- end }} {{- if eq $windows "0" }} volumeMounts: @@ -197,6 +213,10 @@ Create chart name and version as used by the chart label. {{- end }} {{- range .Values.controller.externalHealthMonitorController.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.controller.externalHealthMonitorController.resources }} + resources: +{{ toYaml .Values.controller.externalHealthMonitorController.resources | indent 4 }} {{- end }} {{- if eq $windows "0" }} volumeMounts: @@ -213,6 +233,10 @@ Create chart name and version as used by the chart label. {{- $root := . -}} - name: csi-proxy image: {{ .Values.csiProxy.image }} + {{- if .Values.csiProxy.resources }} + resources: +{{ toYaml .Values.csiProxy.resources | indent 4 }} + {{- end }} env: - name: BIND_TO value: "unix://{{ .csiSocketAddress }}" diff --git a/stable/democratic-csi/templates/controller.yaml b/stable/democratic-csi/templates/controller.yaml index 647c059..f7163e0 100644 --- a/stable/democratic-csi/templates/controller.yaml +++ b/stable/democratic-csi/templates/controller.yaml @@ -98,6 +98,11 @@ spec: - --server-socket=/csi-data/csi.sock {{- end }} + {{- if .Values.controller.driver.resources }} + resources: +{{ toYaml .Values.controller.driver.resources | indent 10 }} + {{- end }} + env: - name: NODE_EXTRA_CA_CERTS value: "/tmp/certs/extra-ca-certs.crt" diff --git a/stable/democratic-csi/templates/csidrivercrd.yaml b/stable/democratic-csi/templates/csidrivercrd.yaml deleted file mode 100644 index bd3a785..0000000 --- a/stable/democratic-csi/templates/csidrivercrd.yaml +++ /dev/null @@ -1,39 +0,0 @@ -{{- if .Values.csiDriver.installCRD -}} ---- -{{- if semverCompare ">=1.16.0-0" .Capabilities.KubeVersion.Version }} -apiVersion: apiextensions.k8s.io/v1 -{{- else }} -apiVersion: apiextensions.k8s.io/v1beta1 -{{- end }} -kind: CustomResourceDefinition -metadata: - name: csidrivers.csi.storage.k8s.io - labels: - addonmanager.kubernetes.io/mode: Reconcile - app.kubernetes.io/name: {{ include "democratic-csi.name" . }} - helm.sh/chart: {{ include "democratic-csi.chart" . }} - app.kubernetes.io/instance: {{ .Release.Name }} - app.kubernetes.io/managed-by: {{ .Release.Service }} -spec: - group: csi.storage.k8s.io - names: - kind: CSIDriver - plural: csidrivers - scope: Cluster - validation: - openAPIV3Schema: - properties: - spec: - description: Specification of the CSI Driver. - properties: - attachRequired: - description: Indicates this CSI volume driver requires an attach operation, - and that Kubernetes should call attach and wait for any attach operation - to complete before proceeding to mount. - type: boolean - podInfoOnMountVersion: - description: Indicates this CSI volume driver requires additional pod - information (like podName, podUID, etc.) during mount operations. - type: string - version: v1alpha1 -{{- end }} diff --git a/stable/democratic-csi/templates/node-windows.yaml b/stable/democratic-csi/templates/node-windows.yaml index 407a28f..5bb0df2 100644 --- a/stable/democratic-csi/templates/node-windows.yaml +++ b/stable/democratic-csi/templates/node-windows.yaml @@ -99,6 +99,11 @@ spec: {{- end }} - --server-socket={{ $csiPipeAddress }} + {{- if .Values.node.driver.resources }} + resources: +{{ toYaml .Values.node.driver.resources | indent 10 }} + {{- end }} + env: - name: CSI_NODE_ID valueFrom: @@ -156,6 +161,10 @@ spec: - {{ tpl . $root }} {{- end }} - --plugin-registration-path={{ .Values.node.kubeletHostPath }}/plugins_registry + {{- if .Values.node.driverRegistrar.resources }} + resources: +{{ toYaml .Values.node.driverRegistrar.resources | indent 10 }} + {{- end }} env: - name: KUBE_NODE_NAME valueFrom: diff --git a/stable/democratic-csi/templates/node.yaml b/stable/democratic-csi/templates/node.yaml index cd55fb4..c199753 100644 --- a/stable/democratic-csi/templates/node.yaml +++ b/stable/democratic-csi/templates/node.yaml @@ -99,6 +99,11 @@ spec: - --server-socket={{ .csiSocketAddress }} {{- end }} + {{- if .Values.node.driver.resources }} + resources: +{{ toYaml .Values.node.driver.resources | indent 10 }} + {{- end }} + securityContext: allowPrivilegeEscalation: true capabilities: @@ -193,6 +198,10 @@ spec: {{- end }} {{- range .Values.node.driverRegistrar.extraArgs }} - {{ tpl . $root }} + {{- end }} + {{- if .Values.node.driverRegistrar.resources }} + resources: +{{ toYaml .Values.node.driverRegistrar.resources | indent 10 }} {{- end }} env: - name: KUBE_NODE_NAME diff --git a/stable/democratic-csi/values.yaml b/stable/democratic-csi/values.yaml index a0878e8..1c68cd1 100644 --- a/stable/democratic-csi/values.yaml +++ b/stable/democratic-csi/values.yaml @@ -39,10 +39,6 @@ csiDriver: # None|File|ReadWriteOnceWithFSType # fsGroupPolicy: ReadWriteOnceWithFSType - # clusters before k8s 1.14 requeired manual installation - # kubectl create -f https://raw.githubusercontent.com/kubernetes/csi-api/master/pkg/crd/manifests/csidriver.yaml - installCRD: false - # k8s 1.16+ # volumeLifecycleModes: [] @@ -87,6 +83,7 @@ controller: - --csi-address={{ .csiSocketAddress }} # if you do not want to completely override the defaults use this extraArgs: [] + resources: # https://kubernetes-csi.github.io/docs/external-provisioner.html externalProvisioner: @@ -102,6 +99,7 @@ controller: - --csi-address={{ .csiSocketAddress }} # if you do not want to completely override the defaults use this extraArgs: [] + resources: # https://kubernetes-csi.github.io/docs/external-resizer.html externalResizer: @@ -116,6 +114,7 @@ controller: - --csi-address={{ .csiSocketAddress }} # if you do not want to completely override the defaults use this extraArgs: [] + resources: # https://kubernetes-csi.github.io/docs/external-snapshotter.html externalSnapshotter: @@ -132,6 +131,7 @@ controller: - --csi-address={{ .csiSocketAddress }} # if you do not want to completely override the defaults use this extraArgs: [] + resources: # https://github.com/kubernetes-csi/external-health-monitor externalHealthMonitorController: @@ -148,6 +148,7 @@ controller: #- --list-volumes-interval # if you do not want to completely override the defaults use this extraArgs: [] + resources: # https://kubernetes-csi.github.io/docs/cluster-driver-registrar.html # not implemented, likely uncessary at this point @@ -178,6 +179,7 @@ controller: # - SYS_ADMIN # privileged: true + resources: extraEnv: [] extraVolumeMounts: [] # - name: foo @@ -235,6 +237,7 @@ node: # exec: # command: ["/bin/sh","-c","nginx -s quit; while killall -0 nginx; do sleep 1; done"] + resources: extraEnv: [] extraVolumeMounts: [] # - name: foo @@ -250,6 +253,7 @@ node: - --kubelet-registration-path={{ .Values.node.kubeletHostPath }}/plugins/{{ .Values.csiDriver.name }}/csi.sock # if you do not want to completely override the defaults use this extraArgs: [] + resources: extraVolumes: [] # - name: foo @@ -312,6 +316,7 @@ volumeSnapshotClasses: [] csiProxy: enabled: true image: docker.io/democraticcsi/csi-grpc-proxy:v0.5.3 + resources: # Configure a pod security policy to allow privileged pods enablePSP: false