From 95428184cc91c82d1303010fb5ddc4847f9fd3e1 Mon Sep 17 00:00:00 2001 From: Travis Athougies Date: Wed, 15 Sep 2021 05:53:50 -0700 Subject: [PATCH] feat(helm): Allow specifying path to zfs binary (#383) * Allow specifying path to zfs binary Some linux/UNIX distributions, do not follow standard path conventions. The driver currently assumes the zfs binary is in /sbin or /usr/sbin, but on NixOS, for example, it's in /run/current-system/sw/bin. This adds an option to specify the directory manually. * Bump chart version Signed-off-by: Travis Athougies --- deploy/helm/charts/Chart.yaml | 2 +- deploy/helm/charts/templates/configmap.yaml | 2 +- deploy/helm/charts/values.yaml | 4 ++++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/deploy/helm/charts/Chart.yaml b/deploy/helm/charts/Chart.yaml index 9965ed6..28696c5 100644 --- a/deploy/helm/charts/Chart.yaml +++ b/deploy/helm/charts/Chart.yaml @@ -1,7 +1,7 @@ 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: 1.9.5 +version: 1.9.6 appVersion: 1.9.1 icon: https://raw.githubusercontent.com/cncf/artwork/master/projects/openebs/icon/color/openebs-icon-color.png home: http://www.openebs.io/ diff --git a/deploy/helm/charts/templates/configmap.yaml b/deploy/helm/charts/templates/configmap.yaml index 2c3d62e..5f1b334 100644 --- a/deploy/helm/charts/templates/configmap.yaml +++ b/deploy/helm/charts/templates/configmap.yaml @@ -13,5 +13,5 @@ data: elif [ -x /host/usr/sbin/zfs ]; then chroot /host /usr/sbin/zfs "$@" else - chroot /host zfs "$@" + chroot /host "{{ .Values.zfs.bin }}" "$@" fi diff --git a/deploy/helm/charts/values.yaml b/deploy/helm/charts/values.yaml index 284818d..1966fd8 100644 --- a/deploy/helm/charts/values.yaml +++ b/deploy/helm/charts/values.yaml @@ -156,3 +156,7 @@ serviceAccount: analytics: enabled: true +zfs: + # If you use a non-standard path to the zfs binary, specify it here + # bin: /run/current-system/sw/bin/zfs + bin: zfs