From b6fed7fa8a3a00156619e79481d25b6815959ff1 Mon Sep 17 00:00:00 2001 From: Hrudaya Ranjan Sahoo Date: Thu, 14 Dec 2023 19:10:05 +0530 Subject: [PATCH] feat(deploy/helm): move volumesnapshot CRDs to the template dir (#488) Signed-off-by: Hrudaya --- deploy/helm/charts/Chart.yaml | 4 ++-- deploy/helm/charts/crds/zfsnode.yaml | 8 ++++++++ .../charts/{crds => templates}/volumesnapshotclasses.yaml | 4 +++- .../{crds => templates}/volumesnapshotcontents.yaml | 4 +++- .../helm/charts/{crds => templates}/volumesnapshots.yaml | 4 +++- deploy/helm/charts/values.yaml | 8 +++++--- 6 files changed, 24 insertions(+), 8 deletions(-) rename deploy/helm/charts/{crds => templates}/volumesnapshotclasses.yaml (98%) rename deploy/helm/charts/{crds => templates}/volumesnapshotcontents.yaml (99%) rename deploy/helm/charts/{crds => templates}/volumesnapshots.yaml (99%) diff --git a/deploy/helm/charts/Chart.yaml b/deploy/helm/charts/Chart.yaml index 20d0fdc14..bbadfff82 100644 --- a/deploy/helm/charts/Chart.yaml +++ b/deploy/helm/charts/Chart.yaml @@ -1,8 +1,8 @@ apiVersion: v2 name: zfs-localpv description: Helm chart for CSI Driver for dynamic provisioning of ZFS Persistent Local Volumes. For instructions on how to use this helm chart, see - https://openebs.github.io/zfs-localpv/ -version: 2.3.2 -appVersion: 2.3.0 +version: 2.4.0 +appVersion: 2.4.0 icon: https://raw.githubusercontent.com/cncf/artwork/master/projects/openebs/icon/color/openebs-icon-color.png home: https://openebs.io/ keywords: diff --git a/deploy/helm/charts/crds/zfsnode.yaml b/deploy/helm/charts/crds/zfsnode.yaml index db0540d4b..065827955 100644 --- a/deploy/helm/charts/crds/zfsnode.yaml +++ b/deploy/helm/charts/crds/zfsnode.yaml @@ -60,6 +60,13 @@ spec: description: Free specifies the available capacity of zfs pool. pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ x-kubernetes-int-or-string: true + used: + anyOf: + - type: integer + - type: string + description: Used specifies the used capacity of zfs pool. + pattern: ^(\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))(([KMGTPE]i)|[numkMGTPE]|([eE](\+|-)?(([0-9]+(\.[0-9]*)?)|(\.[0-9]+))))?$ + x-kubernetes-int-or-string: true name: description: Name of the zfs pool. minLength: 1 @@ -70,6 +77,7 @@ spec: type: string required: - free + - used - name - uuid type: object diff --git a/deploy/helm/charts/crds/volumesnapshotclasses.yaml b/deploy/helm/charts/templates/volumesnapshotclasses.yaml similarity index 98% rename from deploy/helm/charts/crds/volumesnapshotclasses.yaml rename to deploy/helm/charts/templates/volumesnapshotclasses.yaml index 3500b8bb4..dd6d0c5f7 100644 --- a/deploy/helm/charts/crds/volumesnapshotclasses.yaml +++ b/deploy/helm/charts/templates/volumesnapshotclasses.yaml @@ -1,3 +1,4 @@ +{{- if .Values.crd.volumeSnapshot }} --- apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition @@ -131,4 +132,5 @@ status: kind: "" plural: "" conditions: [] - storedVersions: [] \ No newline at end of file + storedVersions: [] +{{- end }} \ No newline at end of file diff --git a/deploy/helm/charts/crds/volumesnapshotcontents.yaml b/deploy/helm/charts/templates/volumesnapshotcontents.yaml similarity index 99% rename from deploy/helm/charts/crds/volumesnapshotcontents.yaml rename to deploy/helm/charts/templates/volumesnapshotcontents.yaml index f69459064..b6d587fea 100644 --- a/deploy/helm/charts/crds/volumesnapshotcontents.yaml +++ b/deploy/helm/charts/templates/volumesnapshotcontents.yaml @@ -1,3 +1,4 @@ +{{- if .Values.crd.volumeSnapshot }} --- apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition @@ -398,4 +399,5 @@ status: kind: "" plural: "" conditions: [] - storedVersions: [] \ No newline at end of file + storedVersions: [] +{{- end }} \ No newline at end of file diff --git a/deploy/helm/charts/crds/volumesnapshots.yaml b/deploy/helm/charts/templates/volumesnapshots.yaml similarity index 99% rename from deploy/helm/charts/crds/volumesnapshots.yaml rename to deploy/helm/charts/templates/volumesnapshots.yaml index bf534c4bd..ac8ce780f 100644 --- a/deploy/helm/charts/crds/volumesnapshots.yaml +++ b/deploy/helm/charts/templates/volumesnapshots.yaml @@ -1,3 +1,4 @@ +{{- if .Values.crd.volumeSnapshot }} --- apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition @@ -309,4 +310,5 @@ status: kind: "" plural: "" conditions: [] - storedVersions: [] \ No newline at end of file + storedVersions: [] +{{- end }} \ No newline at end of file diff --git a/deploy/helm/charts/values.yaml b/deploy/helm/charts/values.yaml index 8bf2f9156..e57bfcfba 100644 --- a/deploy/helm/charts/values.yaml +++ b/deploy/helm/charts/values.yaml @@ -2,7 +2,7 @@ # This is a YAML-formatted file. # Declare variables to be passed into your templates. release: - version: "2.3.1" + version: "2.4.0" imagePullSecrets: # - name: "image-pull-secret" @@ -144,13 +144,15 @@ zfsPlugin: repository: openebs/zfs-driver pullPolicy: IfNotPresent # Overrides the image tag whose default is the chart appVersion. - tag: 2.3.0 + tag: 2.4.0 role: openebs-zfs crd: enableInstall: true - + # Specify installation of the kubernetes-csi volume snapshot CRDs if your Kubernetes distribution + # or another storage operator already manages them. + volumeSnapshot: true serviceAccount: zfsController: # Specifies whether a service account should be created