From 473adf99fcb56c226e446699eea32dd8f2b9c813 Mon Sep 17 00:00:00 2001 From: Prasanna Kumar Kalever Date: Thu, 19 Aug 2021 16:33:39 +0530 Subject: [PATCH] deploy: provide variable to alter hostpath location for ceph clients Also update the documentation about the same. Signed-off-by: Prasanna Kumar Kalever --- charts/ceph-csi-rbd/README.md | 1 + charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml | 2 +- charts/ceph-csi-rbd/templates/nodeplugin-psp.yaml | 2 +- charts/ceph-csi-rbd/values.yaml | 2 ++ 4 files changed, 5 insertions(+), 2 deletions(-) diff --git a/charts/ceph-csi-rbd/README.md b/charts/ceph-csi-rbd/README.md index 9f26025ed..ef2cc6d51 100644 --- a/charts/ceph-csi-rbd/README.md +++ b/charts/ceph-csi-rbd/README.md @@ -138,6 +138,7 @@ charts and their default values. | `provisionerSocketFile` | The filename of the provisioner socket | `csi-provisioner.sock` | | `pluginSocketFile` | The filename of the plugin socket | `csi.sock` | | `kubeletDir` | kubelet working directory | `/var/lib/kubelet` | +| `cephLogDir` | Host path location for ceph client processes logging, ex: rbd-nbd | `/var/log/ceph` | | `driverName` | Name of the csi-driver | `rbd.csi.ceph.com` | | `configMapName` | Name of the configmap which contains cluster configuration | `ceph-csi-config` | | `externallyManagedConfigmap` | Specifies the use of an externally provided configmap | `false` | diff --git a/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml b/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml index bcc50a3e5..003fbf5ec 100644 --- a/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml +++ b/charts/ceph-csi-rbd/templates/nodeplugin-daemonset.yaml @@ -173,7 +173,7 @@ spec: type: DirectoryOrCreate - name: ceph-logdir hostPath: - path: /var/log/ceph + path: {{ .Values.cephLogDir }} type: DirectoryOrCreate - name: host-dev hostPath: diff --git a/charts/ceph-csi-rbd/templates/nodeplugin-psp.yaml b/charts/ceph-csi-rbd/templates/nodeplugin-psp.yaml index 75665484f..fc10f134d 100644 --- a/charts/ceph-csi-rbd/templates/nodeplugin-psp.yaml +++ b/charts/ceph-csi-rbd/templates/nodeplugin-psp.yaml @@ -42,7 +42,7 @@ spec: readOnly: true - pathPrefix: '/lib/modules' readOnly: true - - pathPrefix: '/var/log/ceph' + - pathPrefix: '{{ .Values.cephLogDir }}' readOnly: false - pathPrefix: '{{ .Values.kubeletDir }}' readOnly: false diff --git a/charts/ceph-csi-rbd/values.yaml b/charts/ceph-csi-rbd/values.yaml index 965baff5a..8a00d96d9 100644 --- a/charts/ceph-csi-rbd/values.yaml +++ b/charts/ceph-csi-rbd/values.yaml @@ -382,6 +382,8 @@ provisionerSocketFile: csi-provisioner.sock pluginSocketFile: csi.sock # kubelet working directory,can be set using `--root-dir` when starting kubelet. kubeletDir: /var/lib/kubelet +# Host path location for ceph client processes logging, ex: rbd-nbd +cephLogDir: /var/log/ceph # Name of the csi-driver driverName: rbd.csi.ceph.com # Name of the configmap used for state