From f3a57d3042f57392a76f9c38c31858c940c1e18f Mon Sep 17 00:00:00 2001 From: dntosas Date: Tue, 9 Feb 2021 10:40:21 +0200 Subject: [PATCH 1/7] [chart] Allow resources override for node DaemonSet CSI controller and node have different needs in a manner of capacity so in this commit we enable users to define specific resources for the node component. This will allow users not to reserve not needed resources on all of their instances as node is a DaemonSet and may not need as much CPU/Memory as the controller Pods. Signed-off-by: dntosas --- charts/aws-ebs-csi-driver/Chart.yaml | 2 +- charts/aws-ebs-csi-driver/templates/node.yaml | 18 ++++++++++++++++++ charts/aws-ebs-csi-driver/values.yaml | 1 + 3 files changed, 20 insertions(+), 1 deletion(-) diff --git a/charts/aws-ebs-csi-driver/Chart.yaml b/charts/aws-ebs-csi-driver/Chart.yaml index 13a922b431..4ac72eafb9 100644 --- a/charts/aws-ebs-csi-driver/Chart.yaml +++ b/charts/aws-ebs-csi-driver/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: "0.9.0" name: aws-ebs-csi-driver description: A Helm chart for AWS EBS CSI Driver -version: 0.9.4 +version: 0.9.5 kubeVersion: ">=1.17.0-0" home: https://github.com/kubernetes-sigs/aws-ebs-csi-driver sources: diff --git a/charts/aws-ebs-csi-driver/templates/node.yaml b/charts/aws-ebs-csi-driver/templates/node.yaml index b32958d16a..978c5e729f 100644 --- a/charts/aws-ebs-csi-driver/templates/node.yaml +++ b/charts/aws-ebs-csi-driver/templates/node.yaml @@ -80,9 +80,15 @@ spec: timeoutSeconds: 3 periodSeconds: 10 failureThreshold: 5 + {{- if .Values.node.resources }} + {{- with .Values.node.resources }} + resources: {{ toYaml . | nindent 12 }} + {{- end }} + {{- else }} {{- with .Values.resources }} resources: {{ toYaml . | nindent 12 }} {{- end }} + {{- end }} - name: node-driver-registrar image: {{ printf "%s:%s" .Values.sidecars.nodeDriverRegistrarImage.repository .Values.sidecars.nodeDriverRegistrarImage.tag }} args: @@ -103,9 +109,15 @@ spec: mountPath: /csi - name: registration-dir mountPath: /registration + {{- if .Values.node.resources }} + {{- with .Values.node.resources }} + resources: {{ toYaml . | nindent 12 }} + {{- end }} + {{- else }} {{- with .Values.resources }} resources: {{ toYaml . | nindent 12 }} {{- end }} + {{- end }} - name: liveness-probe image: {{ printf "%s:%s" .Values.sidecars.livenessProbeImage.repository .Values.sidecars.livenessProbeImage.tag }} args: @@ -113,9 +125,15 @@ spec: volumeMounts: - name: plugin-dir mountPath: /csi + {{- if .Values.node.resources }} + {{- with .Values.node.resources }} + resources: {{ toYaml . | nindent 12 }} + {{- end }} + {{- else }} {{- with .Values.resources }} resources: {{ toYaml . | nindent 12 }} {{- end }} + {{- end }} volumes: - name: kubelet-dir hostPath: diff --git a/charts/aws-ebs-csi-driver/values.yaml b/charts/aws-ebs-csi-driver/values.yaml index bb4a609beb..adf3d000f0 100644 --- a/charts/aws-ebs-csi-driver/values.yaml +++ b/charts/aws-ebs-csi-driver/values.yaml @@ -91,6 +91,7 @@ node: podAnnotations: {} tolerateAllTaints: true tolerations: [] + resources: {} serviceAccount: controller: From 5a03305031962bd0b9df0551c1ad80c057cc6b25 Mon Sep 17 00:00:00 2001 From: dntosas Date: Tue, 9 Feb 2021 12:12:40 +0200 Subject: [PATCH 2/7] [chart] Ability to add priorityClassName CSI components and especially the node one, may be critical for operators so in this commit we enable them to define priorities for this kind of Pods. Signed-off-by: dntosas --- charts/aws-ebs-csi-driver/templates/controller.yaml | 2 +- charts/aws-ebs-csi-driver/templates/node.yaml | 2 +- charts/aws-ebs-csi-driver/templates/statefulset.yaml | 2 +- charts/aws-ebs-csi-driver/values.yaml | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/charts/aws-ebs-csi-driver/templates/controller.yaml b/charts/aws-ebs-csi-driver/templates/controller.yaml index 43b5b082cd..24d76df068 100644 --- a/charts/aws-ebs-csi-driver/templates/controller.yaml +++ b/charts/aws-ebs-csi-driver/templates/controller.yaml @@ -27,7 +27,7 @@ spec: {{ toYaml . | indent 8 }} {{- end }} serviceAccountName: {{ .Values.serviceAccount.controller.name }} - priorityClassName: system-cluster-critical + priorityClassName: {{ .Values.priorityClassName | default "system-cluster-critical" }} {{- with .Values.affinity }} affinity: {{ toYaml . | nindent 8 }} {{- end }} diff --git a/charts/aws-ebs-csi-driver/templates/node.yaml b/charts/aws-ebs-csi-driver/templates/node.yaml index 978c5e729f..4a08ad6209 100644 --- a/charts/aws-ebs-csi-driver/templates/node.yaml +++ b/charts/aws-ebs-csi-driver/templates/node.yaml @@ -36,7 +36,7 @@ spec: {{- end }} hostNetwork: true serviceAccountName: {{ .Values.serviceAccount.node.name }} - priorityClassName: system-node-critical + priorityClassName: {{ .Values.node.priorityClassName | default "system-cluster-critical" }} tolerations: {{- if .Values.node.tolerateAllTaints }} - operator: Exists diff --git a/charts/aws-ebs-csi-driver/templates/statefulset.yaml b/charts/aws-ebs-csi-driver/templates/statefulset.yaml index 38fcb9f601..741e26f84c 100644 --- a/charts/aws-ebs-csi-driver/templates/statefulset.yaml +++ b/charts/aws-ebs-csi-driver/templates/statefulset.yaml @@ -26,7 +26,7 @@ spec: {{- with .Values.nodeSelector }} {{ toYaml . | indent 8 }} {{- end }} - priorityClassName: system-cluster-critical + priorityClassName: {{ .Values.priorityClassName | default "system-cluster-critical" }} {{- with .Values.affinity }} affinity: {{ toYaml . | nindent 8 }} {{- end }} diff --git a/charts/aws-ebs-csi-driver/values.yaml b/charts/aws-ebs-csi-driver/values.yaml index adf3d000f0..0017abb363 100644 --- a/charts/aws-ebs-csi-driver/values.yaml +++ b/charts/aws-ebs-csi-driver/values.yaml @@ -60,11 +60,10 @@ resources: # cpu: 100m # memory: 128Mi +priorityClassName: "" nodeSelector: {} - tolerateAllTaints: true tolerations: [] - affinity: {} # Extra volume tags to attach to each dynamically provisioned volume. @@ -87,6 +86,7 @@ k8sTagClusterId: "" region: "" node: + priorityClassName: "" nodeSelector: {} podAnnotations: {} tolerateAllTaints: true From 5b1bb6a97285852bb8e7bbbc1fc00860b29778e2 Mon Sep 17 00:00:00 2001 From: Phillip Thurston Date: Wed, 10 Feb 2021 23:18:06 -0700 Subject: [PATCH 3/7] Updated installation to use latest 0.9 release --- docs/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/README.md b/docs/README.md index e6f1cedc11..6f5a62fc0e 100644 --- a/docs/README.md +++ b/docs/README.md @@ -116,7 +116,7 @@ Please see the compatibility matrix above before you deploy the driver If you want to deploy the stable driver without alpha features: ```sh -kubectl apply -k "github.com/kubernetes-sigs/aws-ebs-csi-driver/deploy/kubernetes/overlays/stable/?ref=release-0.8" +kubectl apply -k "github.com/kubernetes-sigs/aws-ebs-csi-driver/deploy/kubernetes/overlays/stable/?ref=release-0.9" ``` If you want to deploy the driver with alpha features: From 288c17739598b99e5badec4f80dacd5a79cd0446 Mon Sep 17 00:00:00 2001 From: Xiang Li Date: Thu, 11 Feb 2021 12:20:24 -0800 Subject: [PATCH 4/7] patch stable release to use gcr image --- deploy/kubernetes/base/controller.yaml | 6 +++--- deploy/kubernetes/base/node.yaml | 4 ++-- deploy/kubernetes/overlays/stable/kustomization.yaml | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/deploy/kubernetes/base/controller.yaml b/deploy/kubernetes/base/controller.yaml index 24ac7cad7a..87aa706715 100644 --- a/deploy/kubernetes/base/controller.yaml +++ b/deploy/kubernetes/base/controller.yaml @@ -66,7 +66,7 @@ spec: periodSeconds: 10 failureThreshold: 5 - name: csi-provisioner - image: quay.io/k8scsi/csi-provisioner:v2.0.2 + image: k8s.gcr.io/provider-aws/csi-provisioner:v2.0.2 args: - --csi-address=$(ADDRESS) - --v=5 @@ -80,7 +80,7 @@ spec: - name: socket-dir mountPath: /var/lib/csi/sockets/pluginproxy/ - name: csi-attacher - image: quay.io/k8scsi/csi-attacher:v3.0.0 + image: k8s.gcr.io/provider-aws/csi-attacher:v3.0.0 args: - --csi-address=$(ADDRESS) - --v=5 @@ -92,7 +92,7 @@ spec: - name: socket-dir mountPath: /var/lib/csi/sockets/pluginproxy/ - name: liveness-probe - image: quay.io/k8scsi/livenessprobe:v2.1.0 + image: k8s.gcr.io/provider-aws/livenessprobe:v2.1.0 args: - --csi-address=/csi/csi.sock volumeMounts: diff --git a/deploy/kubernetes/base/node.yaml b/deploy/kubernetes/base/node.yaml index 79c332d8a9..05f52d6958 100644 --- a/deploy/kubernetes/base/node.yaml +++ b/deploy/kubernetes/base/node.yaml @@ -69,7 +69,7 @@ spec: periodSeconds: 10 failureThreshold: 5 - name: node-driver-registrar - image: quay.io/k8scsi/csi-node-driver-registrar:v2.0.1 + image: k8s.gcr.io/provider-aws/csi-node-driver-registrar:v2.0.1 args: - --csi-address=$(ADDRESS) - --kubelet-registration-path=$(DRIVER_REG_SOCK_PATH) @@ -89,7 +89,7 @@ spec: - name: registration-dir mountPath: /registration - name: liveness-probe - image: quay.io/k8scsi/livenessprobe:v2.1.0 + image: k8s.gcr.io/provider-aws/livenessprobe:v2.1.0 args: - --csi-address=/csi/csi.sock volumeMounts: diff --git a/deploy/kubernetes/overlays/stable/kustomization.yaml b/deploy/kubernetes/overlays/stable/kustomization.yaml index 3c90c2582b..d5eacc1a2e 100644 --- a/deploy/kubernetes/overlays/stable/kustomization.yaml +++ b/deploy/kubernetes/overlays/stable/kustomization.yaml @@ -5,11 +5,11 @@ bases: images: - name: k8s.gcr.io/provider-aws/aws-ebs-csi-driver newTag: v0.9.0 - - name: quay.io/k8scsi/csi-provisioner + - name: k8s.gcr.io/provider-aws/csi-provisioner newTag: v2.0.2 - - name: quay.io/k8scsi/csi-attacher + - name: k8s.gcr.io/provider-aws/csi-attacher newTag: v3.0.0 - - name: quay.io/k8scsi/livenessprobe + - name: k8s.gcr.io/provider-aws/livenessprobe newTag: v2.1.0 - - name: quay.io/k8scsi/csi-node-driver-registrar + - name: k8s.gcr.io/provider-aws/csi-node-driver-registrar newTag: v2.0.1 From 41d8f2e2620bc55b1925f74e9eb0c82591fcbe50 Mon Sep 17 00:00:00 2001 From: Xiang Li Date: Thu, 11 Feb 2021 16:17:23 -0800 Subject: [PATCH 5/7] correct kustomization gcr image repo --- deploy/kubernetes/base/controller.yaml | 8 ++++---- deploy/kubernetes/base/node.yaml | 6 +++--- deploy/kubernetes/overlays/stable/kustomization.yaml | 8 ++++---- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/deploy/kubernetes/base/controller.yaml b/deploy/kubernetes/base/controller.yaml index 87aa706715..10bebd9c06 100644 --- a/deploy/kubernetes/base/controller.yaml +++ b/deploy/kubernetes/base/controller.yaml @@ -28,7 +28,7 @@ spec: - operator: Exists containers: - name: ebs-plugin - image: k8s.gcr.io/provider-aws/aws-ebs-csi-driver:latest + image: k8s.gcr.io/provider-aws/aws-ebs-csi-driver:v0.9.0 imagePullPolicy: IfNotPresent args: # - {all,controller,node} # specify the driver mode @@ -66,7 +66,7 @@ spec: periodSeconds: 10 failureThreshold: 5 - name: csi-provisioner - image: k8s.gcr.io/provider-aws/csi-provisioner:v2.0.2 + image: k8s.gcr.io/sig-storage/csi-provisioner:v2.0.2 args: - --csi-address=$(ADDRESS) - --v=5 @@ -80,7 +80,7 @@ spec: - name: socket-dir mountPath: /var/lib/csi/sockets/pluginproxy/ - name: csi-attacher - image: k8s.gcr.io/provider-aws/csi-attacher:v3.0.0 + image: k8s.gcr.io/sig-storage/csi-attacher:v3.0.0 args: - --csi-address=$(ADDRESS) - --v=5 @@ -92,7 +92,7 @@ spec: - name: socket-dir mountPath: /var/lib/csi/sockets/pluginproxy/ - name: liveness-probe - image: k8s.gcr.io/provider-aws/livenessprobe:v2.1.0 + image: k8s.gcr.io/sig-storage/livenessprobe:v2.1.0 args: - --csi-address=/csi/csi.sock volumeMounts: diff --git a/deploy/kubernetes/base/node.yaml b/deploy/kubernetes/base/node.yaml index 05f52d6958..2f11c221c3 100644 --- a/deploy/kubernetes/base/node.yaml +++ b/deploy/kubernetes/base/node.yaml @@ -39,7 +39,7 @@ spec: - name: ebs-plugin securityContext: privileged: true - image: k8s.gcr.io/provider-aws/aws-ebs-csi-driver:latest + image: k8s.gcr.io/provider-aws/aws-ebs-csi-driver:v0.9.0 args: - node - --endpoint=$(CSI_ENDPOINT) @@ -69,7 +69,7 @@ spec: periodSeconds: 10 failureThreshold: 5 - name: node-driver-registrar - image: k8s.gcr.io/provider-aws/csi-node-driver-registrar:v2.0.1 + image: k8s.gcr.io/sig-storage/csi-node-driver-registrar:v2.0.1 args: - --csi-address=$(ADDRESS) - --kubelet-registration-path=$(DRIVER_REG_SOCK_PATH) @@ -89,7 +89,7 @@ spec: - name: registration-dir mountPath: /registration - name: liveness-probe - image: k8s.gcr.io/provider-aws/livenessprobe:v2.1.0 + image: k8s.gcr.io/sig-storage/livenessprobe:v2.1.0 args: - --csi-address=/csi/csi.sock volumeMounts: diff --git a/deploy/kubernetes/overlays/stable/kustomization.yaml b/deploy/kubernetes/overlays/stable/kustomization.yaml index d5eacc1a2e..707aa90269 100644 --- a/deploy/kubernetes/overlays/stable/kustomization.yaml +++ b/deploy/kubernetes/overlays/stable/kustomization.yaml @@ -5,11 +5,11 @@ bases: images: - name: k8s.gcr.io/provider-aws/aws-ebs-csi-driver newTag: v0.9.0 - - name: k8s.gcr.io/provider-aws/csi-provisioner + - name: k8s.gcr.io/sig-storage/csi-provisioner newTag: v2.0.2 - - name: k8s.gcr.io/provider-aws/csi-attacher + - name: k8s.gcr.io/sig-storage/csi-attacher newTag: v3.0.0 - - name: k8s.gcr.io/provider-aws/livenessprobe + - name: k8s.gcr.io/sig-storage/livenessprobe newTag: v2.1.0 - - name: k8s.gcr.io/provider-aws/csi-node-driver-registrar + - name: k8s.gcr.io/sig-storage/csi-node-driver-registrar newTag: v2.0.1 From e2de85d3a49fbe3c6327eedf039741c75b37438e Mon Sep 17 00:00:00 2001 From: Ayberk Yilmaz Date: Fri, 12 Feb 2021 13:50:04 -0800 Subject: [PATCH 6/7] Update ECR overlay --- .../overlays/stable/ecr/kustomization.yaml | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml b/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml index 87763d30a2..6ce8adcb22 100644 --- a/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml +++ b/deploy/kubernetes/overlays/stable/ecr/kustomization.yaml @@ -5,16 +5,16 @@ bases: images: - name: k8s.gcr.io/provider-aws/aws-ebs-csi-driver newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/aws-ebs-csi-driver - newTag: v0.7.1 + newTag: v0.9.0 - name: quay.io/k8scsi/csi-provisioner - newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/csi-provisioner - newTag: v1.5.0 + newName: public.ecr.aws/eks-distro/kubernetes-csi/external-provisioner + newTag: v2.0.3-eks-1-18-1 - name: quay.io/k8scsi/csi-attacher - newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/csi-attacher - newTag: v1.2.0 + newName: public.ecr.aws/eks-distro/kubernetes-csi/external-attacher + newTag: v3.0.1-eks-1-18-1 - name: quay.io/k8scsi/livenessprobe - newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/csi-liveness-probe - newTag: v1.1.0 + newName: public.ecr.aws/eks-distro/kubernetes-csi/livenessprobe + newTag: v2.1.0-eks-1-18-1 - name: quay.io/k8scsi/csi-node-driver-registrar - newName: 602401143452.dkr.ecr.us-west-2.amazonaws.com/eks/csi-node-driver-registrar - newTag: v1.1.0 + newName: public.ecr.aws/eks-distro/kubernetes-csi/node-driver-registrar + newTag: v2.0.1-eks-1-18-1 From 78d23ca81c230bc92b199b59c3276b6628f34a08 Mon Sep 17 00:00:00 2001 From: Anil Karatas Date: Sat, 13 Feb 2021 18:55:52 +0100 Subject: [PATCH 7/7] add snapshot controller variables --- charts/aws-ebs-csi-driver/Chart.yaml | 2 +- charts/aws-ebs-csi-driver/templates/statefulset.yaml | 2 +- charts/aws-ebs-csi-driver/values.yaml | 4 ++++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/charts/aws-ebs-csi-driver/Chart.yaml b/charts/aws-ebs-csi-driver/Chart.yaml index 4ac72eafb9..9adc31de1b 100644 --- a/charts/aws-ebs-csi-driver/Chart.yaml +++ b/charts/aws-ebs-csi-driver/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v1 appVersion: "0.9.0" name: aws-ebs-csi-driver description: A Helm chart for AWS EBS CSI Driver -version: 0.9.5 +version: 0.9.6 kubeVersion: ">=1.17.0-0" home: https://github.com/kubernetes-sigs/aws-ebs-csi-driver sources: diff --git a/charts/aws-ebs-csi-driver/templates/statefulset.yaml b/charts/aws-ebs-csi-driver/templates/statefulset.yaml index 741e26f84c..1a28857e14 100644 --- a/charts/aws-ebs-csi-driver/templates/statefulset.yaml +++ b/charts/aws-ebs-csi-driver/templates/statefulset.yaml @@ -39,7 +39,7 @@ spec: {{- end }} containers: - name: snapshot-controller - image: k8s.gcr.io/sig-storage/snapshot-controller:v3.0.3 + image: {{ printf "%s:%s" .Values.snapshotController.repository .Values.snapshotController.tag }} args: - --v=5 - --leader-election=false diff --git a/charts/aws-ebs-csi-driver/values.yaml b/charts/aws-ebs-csi-driver/values.yaml index 0017abb363..ca318bab09 100644 --- a/charts/aws-ebs-csi-driver/values.yaml +++ b/charts/aws-ebs-csi-driver/values.yaml @@ -29,6 +29,10 @@ sidecars: repository: k8s.gcr.io/sig-storage/csi-node-driver-registrar tag: "v2.0.1" +snapshotController: + repository: k8s.gcr.io/sig-storage/snapshot-controller + tag: "v3.0.3" + imagePullSecrets: [] nameOverride: "" fullnameOverride: ""