From 64e7be1bcb7dc1bde00a84ecebe07f926485b318 Mon Sep 17 00:00:00 2001 From: Vicente Cheng Date: Wed, 17 May 2023 18:25:23 +0800 Subject: [PATCH] make charts Signed-off-by: Vicente Cheng --- .../harvester-csi-driver-102.0.1+up0.1.16.tgz | Bin 0 -> 3764 bytes .../102.0.1+up0.1.16/.helmignore | 23 +++ .../102.0.1+up0.1.16/Chart.yaml | 22 +++ .../102.0.1+up0.1.16/questions.yml | 11 ++ .../102.0.1+up0.1.16/templates/NOTES.txt | 1 + .../102.0.1+up0.1.16/templates/_helpers.tpl | 62 ++++++++ .../102.0.1+up0.1.16/templates/csidriver.yaml | 10 ++ .../102.0.1+up0.1.16/templates/daemonset.yaml | 149 ++++++++++++++++++ .../templates/deployment.yaml | 95 +++++++++++ .../102.0.1+up0.1.16/templates/rbac.yaml | 75 +++++++++ .../templates/storageclass.yaml | 10 ++ .../102.0.1+up0.1.16/values.yaml | 54 +++++++ index.yaml | 26 +++ 13 files changed, 538 insertions(+) create mode 100644 assets/harvester-csi-driver/harvester-csi-driver-102.0.1+up0.1.16.tgz create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/.helmignore create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/Chart.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/questions.yml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/NOTES.txt create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/_helpers.tpl create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/csidriver.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/daemonset.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/deployment.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/rbac.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/templates/storageclass.yaml create mode 100644 charts/harvester-csi-driver/102.0.1+up0.1.16/values.yaml diff --git a/assets/harvester-csi-driver/harvester-csi-driver-102.0.1+up0.1.16.tgz b/assets/harvester-csi-driver/harvester-csi-driver-102.0.1+up0.1.16.tgz new file mode 100644 index 0000000000000000000000000000000000000000..727a7fc11c9a4946a684f9dd09285da879133c98 GIT binary patch literal 3764 zcmV;l4omSLiwG0|00000|0w_~VMtOiV@ORlOnEsqVl!4SWK%V1T2nbTPgYhoO;>Dc zVQyr3R8em|NM&qo0PH+#bK5wQ`OII@$7E|W*(LSxYf5##s;uSRb=|~vMN^sDy1H^f zWJ|&t1ULYwSTo7}_A3A+MN-tmk2sSV;e$;PK)=x4Xfy!Mh@7L+D1%7RAeMBFvU4^g zQiltYuoq8Jy4`N~`0&vF?{>S*|Gk6W@r&N!;X$w0KRWK7yy*6h`iDm^p!+1)x0Fn2 zB42bLjjPGrH&O`aLK95|R|5|qBAPHU4I`p8!;p$jgi_N9#drXc@MwmzwOLG6%E%(% zB*6jvv(PFy8(qNAYE^5u+iZ-%9HpXy58%)Lbqc+(e-L(qF8rr?JTZ@dZtZF?sgy)G z01HJel*XjBsZax8lxKIXwJFMkY87m5l`~%_wjZA4wD!aA*OMxdAyJqMr_JPAyJa+p zM3M@QT;Hc#s&|)8xpDQALub+P-@W|3sERWSjv^ zglvpzPQfiMJ_;GDffoSf6G@boS)?#~JY)Hb}AQ`<#aR4Mu8I7!> zdL>`IZa?gXy}x8>&f(X#rf;vb`u{m$8LB6n0Jix5{=vaX)BhiJPxk)*Im$~I;)G;O zgBx^f=xs_7dY(jUgX&CV#vvVe9! zFX3vAQqmX|=ox~=1DZ_X<4h=oIH#GqYUiSs{w&PFXfhpu?|hr@S+X2KT*T-Ie2-JA zv?LoTO{kPYVjM8Rr!yfr6_#cLCMP_Q1)wVKc|SY|yPkuq=r5ZEvJOq&wFbBs_H)3g z6mx30ei-md_Xg#?uy5ZGt%(8g5a>nU8t8+tAND+eG-K>qFd8iea51?Q`dXqwu01;) z6dEu9-}fdNV=FH`Gw(Ch?}gAqDhJS+6W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H@=SLgN%;4r;tLQFF+!6jC0~z_j?zSDEA%)dEsz@;(1NEJd`6U75qUeK zZFo3I)lBGcJHmW$^9~y^J|&_^a3jon;@jDVOuW9U-L%?jJ7k<&npfc7!w~O*Efw*j zcpz!2+94N-cx+?FAlTI`oSYx3r90}3TTUk1)TJu_br!gr0$jCw`wwTx5<2BV;#1(*X8%Xc`=7m|!=wHEuV*PQ;hJcTk}J>x+?d118FCnBlo?xr zlti~=iYoM8!jChmKxJtvq*kD2$QVqS7`xqa%BOz?iHvAEN1My5yeB;NUIIsV6cb*j z5-0QyW0!>dkMBab;%ote+n$CbNKpc#978W0j&6(_LhmKy-yisJHiDQ+<%LtKJNB<5 z-wVgT$d3J6yqHZp=1=ic&3R`DXiTEpEVbW0QQn(SeN4SK;h5ZdZ$h1zXCdj-d-H$Z zOZY$}6`6vI;koj{R0^|H_CgvX>A2=n{M!rXDiSevz6H0^YX3iHsH_hU7f@- zulfDYT2D{DAM8&n=g#V!F?Xq-4yBqqvQOt3`5U0B5Ea+(BJy zch*;U0JZNA`=b;iI&q&!vCgFU;!ve~=z9QDmmKr+k3N`JF5$1VqY?HN_X782U-sn>RQ^8z0RR6)6^Ri5VgLZY8ea7P literal 0 HcmV?d00001 diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/.helmignore b/charts/harvester-csi-driver/102.0.1+up0.1.16/.helmignore new file mode 100644 index 000000000..0e8a0eb36 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/Chart.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/Chart.yaml new file mode 100644 index 000000000..d361eee9c --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/Chart.yaml @@ -0,0 +1,22 @@ +annotations: + catalog.cattle.io/certified: rancher + catalog.cattle.io/display-name: Harvester CSI Driver + catalog.cattle.io/kube-version: '>= 1.23.0-0 < 1.27.0-0' + catalog.cattle.io/namespace: kube-system + catalog.cattle.io/os: linux + catalog.cattle.io/permits-os: linux + catalog.cattle.io/rancher-version: '>= 2.7.0-0 < 2.8.0-0' + catalog.cattle.io/release-name: harvester-csi-driver + catalog.cattle.io/ui-component: harvester-csi-driver + catalog.cattle.io/upstream-version: 0.1.16 +apiVersion: v2 +appVersion: v0.1.5 +description: A Helm chart for Harvester CSI driver +keywords: +- infrastructure +- harvester +maintainers: +- name: harvester +name: harvester-csi-driver +type: application +version: 102.0.1+up0.1.16 diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/questions.yml b/charts/harvester-csi-driver/102.0.1+up0.1.16/questions.yml new file mode 100644 index 000000000..0c703a0f2 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/questions.yml @@ -0,0 +1,11 @@ +categories: +- infrastructure +- harvester +namespace: kube-system +questions: +- variable: cloudConfig.hostPath + label: Cloud config file path + description: "Specify the path of the cloud config." + group: "Default" + type: string + default: "/etc/kubernetes/cloud-config" diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/NOTES.txt b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/NOTES.txt new file mode 100644 index 000000000..ba09c6d51 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/NOTES.txt @@ -0,0 +1 @@ +Successfully deployed Harvester CSI driver to the {{ .Release.Namespace }} namespace. diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/_helpers.tpl b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/_helpers.tpl new file mode 100644 index 000000000..def471b21 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/_helpers.tpl @@ -0,0 +1,62 @@ +{{/* vim: set filetype=mustache: */}} +{{/* +Expand the name of the chart. +*/}} +{{- define "harvester-csi-driver.name" -}} +{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Create a default fully qualified app name. +We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). +If release name contains chart name it will be used as a full name. +*/}} +{{- define "harvester-csi-driver.fullname" -}} +{{- if .Values.fullnameOverride }} +{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} +{{- else }} +{{- $name := default .Chart.Name .Values.nameOverride }} +{{- if contains $name .Release.Name }} +{{- .Release.Name | trunc 63 | trimSuffix "-" }} +{{- else }} +{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} +{{- end }} +{{- end }} +{{- end }} + +{{/* +Create chart name and version as used by the chart label. +*/}} +{{- define "harvester-csi-driver.chart" -}} +{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} +{{- end }} + +{{/* +Common labels +*/}} +{{- define "harvester-csi-driver.labels" -}} +helm.sh/chart: {{ include "harvester-csi-driver.chart" . }} +{{ include "harvester-csi-driver.selectorLabels" . }} +{{- if .Chart.AppVersion }} +app.kubernetes.io/version: {{ .Chart.AppVersion | quote }} +{{- end }} +{{- end }} + +{{/* +Selector labels +*/}} +{{- define "harvester-csi-driver.selectorLabels" -}} +app.kubernetes.io/name: {{ include "harvester-csi-driver.name" . }} +app.kubernetes.io/instance: {{ .Release.Name }} +{{- end }} + +{{/* +Global system default registry +*/}} +{{- define "system_default_registry" -}} +{{- if .Values.global.cattle.systemDefaultRegistry -}} +{{- printf "%s/" .Values.global.cattle.systemDefaultRegistry -}} +{{- else -}} +{{- "" -}} +{{- end -}} +{{- end -}} diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/csidriver.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/csidriver.yaml new file mode 100644 index 000000000..5fc6ec84a --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/csidriver.yaml @@ -0,0 +1,10 @@ +apiVersion: storage.k8s.io/v1 +kind: CSIDriver +metadata: + name: driver.harvesterhci.io +spec: + attachRequired: true + fsGroupPolicy: ReadWriteOnceWithFSType + podInfoOnMount: true + volumeLifecycleModes: + - Persistent diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/daemonset.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/daemonset.yaml new file mode 100644 index 000000000..e995ee65b --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/daemonset.yaml @@ -0,0 +1,149 @@ +apiVersion: apps/v1 +kind: DaemonSet +metadata: + name: {{ include "harvester-csi-driver.name" . }} + namespace: {{ .Release.Namespace }} + labels: + {{- include "harvester-csi-driver.labels" . | nindent 4 }} +spec: + selector: + matchLabels: + component: csi-driver + {{- include "harvester-csi-driver.selectorLabels" . | nindent 6 }} + template: + metadata: + labels: + component: csi-driver + {{- include "harvester-csi-driver.selectorLabels" . | nindent 8 }} + spec: + containers: + - args: + - --v=5 + - --csi-address=$(ADDRESS) + - --kubelet-registration-path={{ .Values.kubeletRootDir }}/harvester-plugins/driver.harvesterhci.io/csi.sock + env: + - name: ADDRESS + value: /csi/csi.sock + image: {{ template "system_default_registry" . }}{{ .Values.image.csi.nodeDriverRegistrar.repository }}:{{ .Values.image.csi.nodeDriverRegistrar.tag }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + lifecycle: + preStop: + exec: + command: + - /bin/sh + - -c + - rm -rf /registration/driver.harvesterhci.io-reg.sock + /csi//* + name: node-driver-registrar + securityContext: + privileged: true + volumeMounts: + - mountPath: /csi/ + name: socket-dir + - mountPath: /registration + name: registration-dir + - args: + - --nodeid=$(NODE_ID) + - --endpoint=$(CSI_ENDPOINT) + - --kubeconfig=/var/lib/harvester/cloud-provider-config + env: + - name: NODE_ID + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: spec.nodeName + - name: CSI_ENDPOINT + value: unix:///csi/csi.sock + image: {{ template "system_default_registry" . }}{{ .Values.image.harvester.csiDriver.repository }}:{{ .Values.image.harvester.csiDriver.tag | default .Chart.AppVersion }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + lifecycle: + preStop: + exec: + command: + - /bin/sh + - -c + - rm -f /csi//* + name: harvester-csi-driver + securityContext: + allowPrivilegeEscalation: true + capabilities: + add: + - SYS_ADMIN + privileged: true + volumeMounts: + - name: cloud-config + readOnly: true + mountPath: /var/lib/harvester + - name: kubernetes + readOnly: true + mountPath: /etc/kubernetes + - mountPath: {{ .Values.kubeletRootDir }}/plugins/kubernetes.io/csi + mountPropagation: Bidirectional + name: kubernetes-csi-dir + - mountPath: /csi/ + name: socket-dir + - mountPath: {{ .Values.kubeletRootDir }}/pods + mountPropagation: Bidirectional + name: pods-mount-dir + - mountPath: /dev + name: host-dev + - mountPath: /sys + name: host-sys + - mountPath: /rootfs + mountPropagation: Bidirectional + name: host + - mountPath: /lib/modules + name: lib-modules + readOnly: true + hostPID: true + serviceAccountName: {{ include "harvester-csi-driver.name" . }} + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + volumes: + - name: cloud-config + {{- if .Values.cloudConfig.secretName }} + secret: + secretName: {{ .Values.cloudConfig.secretName }} + {{- else }} + hostPath: + path: {{ .Values.cloudConfig.hostPath }} + type: DirectoryOrCreate + {{- end }} + - hostPath: + path: /etc/kubernetes + type: DirectoryOrCreate + name: kubernetes + - hostPath: + path: {{ .Values.kubeletRootDir }}/plugins/kubernetes.io/csi + type: DirectoryOrCreate + name: kubernetes-csi-dir + - hostPath: + path: {{ .Values.kubeletRootDir }}/plugins_registry + type: Directory + name: registration-dir + - hostPath: + path: {{ .Values.kubeletRootDir }}/harvester-plugins/driver.harvesterhci.io + type: DirectoryOrCreate + name: socket-dir + - hostPath: + path: {{ .Values.kubeletRootDir }}/pods + type: DirectoryOrCreate + name: pods-mount-dir + - hostPath: + path: /dev + name: host-dev + - hostPath: + path: /sys + name: host-sys + - hostPath: + path: / + name: host + - hostPath: + path: /lib/modules + name: lib-modules diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/deployment.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/deployment.yaml new file mode 100644 index 000000000..bb511dfa7 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/deployment.yaml @@ -0,0 +1,95 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: {{ include "harvester-csi-driver.name" . }}-controllers + namespace: {{ .Release.Namespace }} + labels: + {{- include "harvester-csi-driver.labels" . | nindent 4 }} +spec: + replicas: {{ .Values.replicasCount }} + selector: + matchLabels: + component: csi-controllers + {{- include "harvester-csi-driver.selectorLabels" . | nindent 6 }} + template: + metadata: + labels: + component: csi-controllers + {{- include "harvester-csi-driver.selectorLabels" . | nindent 8 }} + spec: + containers: + - args: + - --v=5 + - --csi-address=$(ADDRESS) + - --timeout=1m50s + - --leader-election + - --leader-election-namespace=$(POD_NAMESPACE) + env: + - name: ADDRESS + value: /csi/csi.sock + - name: POD_NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ template "system_default_registry" . }}{{ .Values.image.csi.resizer.repository }}:{{ .Values.image.csi.resizer.tag }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + name: csi-resizer + volumeMounts: + - mountPath: /csi/ + name: socket-dir + - args: + - --v=5 + - --csi-address=$(ADDRESS) + - --timeout=1m50s + - --leader-election + - --leader-election-namespace=$(POD_NAMESPACE) + - --default-fstype=ext4 + env: + - name: ADDRESS + value: /csi/csi.sock + - name: POD_NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ template "system_default_registry" . }}{{ .Values.image.csi.provisioner.repository }}:{{ .Values.image.csi.provisioner.tag }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + name: csi-provisioner + volumeMounts: + - mountPath: /csi/ + name: socket-dir + - args: + - --v=5 + - --csi-address=$(ADDRESS) + - --timeout=1m50s + - --leader-election + - --leader-election-namespace=$(POD_NAMESPACE) + env: + - name: ADDRESS + value: /csi/csi.sock + - name: POD_NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + image: {{ template "system_default_registry" . }}{{ .Values.image.csi.attacher.repository }}:{{ .Values.image.csi.attacher.tag }} + imagePullPolicy: {{ .Values.image.pullPolicy }} + name: csi-attacher + volumeMounts: + - mountPath: /csi/ + name: socket-dir + serviceAccountName: {{ include "harvester-csi-driver.name" . }} + {{- with .Values.nodeSelector }} + nodeSelector: + {{- toYaml . | nindent 8 }} + {{- end }} + {{- with .Values.tolerations }} + tolerations: + {{- toYaml . | nindent 8 }} + {{- end }} + volumes: + - hostPath: + path: {{ .Values.kubeletRootDir }}/harvester-plugins/driver.harvesterhci.io + type: DirectoryOrCreate + name: socket-dir diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/rbac.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/rbac.yaml new file mode 100644 index 000000000..2ba042a26 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/rbac.yaml @@ -0,0 +1,75 @@ +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "harvester-csi-driver.name" . }} + namespace: {{ .Release.Namespace }} + labels: + {{- include "harvester-csi-driver.labels" . | nindent 4 }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: {{ include "harvester-csi-driver.name" . }} + labels: + {{- include "harvester-csi-driver.labels" . | nindent 4 }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: {{ include "harvester-csi-driver.name" . }} +subjects: + - kind: ServiceAccount + name: {{ include "harvester-csi-driver.name" . }} + namespace: {{ .Release.Namespace }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "harvester-csi-driver.name" . }} + labels: + {{- include "harvester-csi-driver.labels" . | nindent 4 }} +rules: + - apiGroups: [ "coordination.k8s.io" ] + resources: [ "leases" ] + verbs: [ "get", "watch", "list", "delete", "update", "create" ] + - apiGroups: [ "storage.k8s.io" ] + resources: [ "csistoragecapacities" ] + verbs: [ "get", "list", "watch", "create", "update", "patch", "delete" ] + - apiGroups: [""] + resources: ["persistentvolumes"] + verbs: [ "get", "list", "watch", "create","update", "patch", "delete" ] + - apiGroups: [""] + resources: ["persistentvolumeclaims"] + verbs: ["get", "list", "watch", "create","update", "patch", "delete" ] + - apiGroups: [""] + resources: ["persistentvolumeclaims/status"] + verbs: ["patch"] + - apiGroups: ["storage.k8s.io"] + resources: ["storageclasses"] + verbs: ["get", "list", "watch"] + - apiGroups: ["snapshot.storage.k8s.io"] + resources: ["volumesnapshots"] + verbs: ["get", "list"] + - apiGroups: ["snapshot.storage.k8s.io"] + resources: ["volumesnapshotcontents"] + verbs: ["get", "list"] + - apiGroups: [ "storage.k8s.io" ] + resources: [ "csinodes" ] + verbs: [ "get", "list", "watch" ] + - apiGroups: [ "" ] + resources: [ "events" ] + verbs: [ "list", "watch", "create", "update", "patch" ] + - apiGroups: [ "" ] + resources: [ "pods" ] + verbs: [ "get", "list", "watch" ] + - apiGroups: [ "apps" ] + resources: [ "replicasets" ] + verbs: [ "get" ] + - apiGroups: [""] + resources: ["nodes"] + verbs: ["get", "list", "watch"] + - apiGroups: ["storage.k8s.io"] + resources: ["volumeattachments"] + verbs: ["get", "list", "watch", "patch"] + - apiGroups: [ "storage.k8s.io" ] + resources: [ "volumeattachments/status" ] + verbs: [ "patch" ] diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/storageclass.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/storageclass.yaml new file mode 100644 index 000000000..a29c9c7da --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/templates/storageclass.yaml @@ -0,0 +1,10 @@ +apiVersion: storage.k8s.io/v1 +kind: StorageClass +metadata: + name: harvester + annotations: + storageclass.kubernetes.io/is-default-class: "true" +allowVolumeExpansion: true +provisioner: driver.harvesterhci.io +reclaimPolicy: Delete +volumeBindingMode: Immediate diff --git a/charts/harvester-csi-driver/102.0.1+up0.1.16/values.yaml b/charts/harvester-csi-driver/102.0.1+up0.1.16/values.yaml new file mode 100644 index 000000000..aadeb7663 --- /dev/null +++ b/charts/harvester-csi-driver/102.0.1+up0.1.16/values.yaml @@ -0,0 +1,54 @@ +# Default values for harvester-csi-driver. + +replicasCount: 3 + +image: + harvester: + csiDriver: + repository: rancher/harvester-csi-driver + # Overrides the image tag whose default is the chart appVersion. + tag: "v0.1.5" + csi: + nodeDriverRegistrar: + repository: rancher/mirrored-longhornio-csi-node-driver-registrar + tag: v2.3.0 + resizer: + repository: rancher/mirrored-longhornio-csi-resizer + tag: v1.2.0 + provisioner: + repository: rancher/mirrored-longhornio-csi-provisioner + tag: v2.1.2 + attacher: + repository: rancher/mirrored-longhornio-csi-attacher + tag: v3.2.1 + pullPolicy: IfNotPresent + +nameOverride: "" +fullnameOverride: "" + +kubeletRootDir: /var/lib/kubelet +cloudConfig: + secretName: "" + hostPath: "/var/lib/rancher/rke2/etc/config-files/" + +nodeSelector: + kubernetes.io/os: linux + +tolerations: + - effect: NoSchedule + key: kubevirt.io/drain + operator: Exists + - effect: NoSchedule + key: node-role.kubernetes.io/control-plane + operator: Equal + - effect: NoExecute + key: node-role.kubernetes.io/etcd + operator: Equal + - key: cattle.io/os + operator: Equal + value: "linux" + effect: NoSchedule + +global: + cattle: + systemDefaultRegistry: "" diff --git a/index.yaml b/index.yaml index 88cce7b74..f44c2e6dd 100755 --- a/index.yaml +++ b/index.yaml @@ -1733,6 +1733,32 @@ entries: - assets/harvester-cloud-provider/harvester-cloud-provider-100.0.0+up0.1.8.tgz version: 100.0.0+up0.1.8 harvester-csi-driver: + - annotations: + catalog.cattle.io/certified: rancher + catalog.cattle.io/display-name: Harvester CSI Driver + catalog.cattle.io/kube-version: '>= 1.23.0-0 < 1.27.0-0' + catalog.cattle.io/namespace: kube-system + catalog.cattle.io/os: linux + catalog.cattle.io/permits-os: linux + catalog.cattle.io/rancher-version: '>= 2.7.0-0 < 2.8.0-0' + catalog.cattle.io/release-name: harvester-csi-driver + catalog.cattle.io/ui-component: harvester-csi-driver + catalog.cattle.io/upstream-version: 0.1.16 + apiVersion: v2 + appVersion: v0.1.5 + created: "2023-05-17T18:25:11.297838815+08:00" + description: A Helm chart for Harvester CSI driver + digest: f35c39366a15cc1f22fc7cfafdd810ef38cfdc31d61bba7cdeb941012bc617b4 + keywords: + - infrastructure + - harvester + maintainers: + - name: harvester + name: harvester-csi-driver + type: application + urls: + - assets/harvester-csi-driver/harvester-csi-driver-102.0.1+up0.1.16.tgz + version: 102.0.1+up0.1.16 - annotations: catalog.cattle.io/certified: rancher catalog.cattle.io/display-name: Harvester CSI Driver