diff --git a/charts/nextcloud/Chart.yaml b/charts/nextcloud/Chart.yaml index 3633ea10..db560bbd 100644 --- a/charts/nextcloud/Chart.yaml +++ b/charts/nextcloud/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 name: nextcloud -version: 8.6.0 +version: 8.7.0 # renovate: image=docker.io/library/nextcloud appVersion: 32.0.2 description: A file sharing server that puts the control and security of your own data back into your hands. diff --git a/charts/nextcloud/README.md b/charts/nextcloud/README.md index e8282141..f28c942c 100644 --- a/charts/nextcloud/README.md +++ b/charts/nextcloud/README.md @@ -405,6 +405,7 @@ Nextcloud will *not* delete the PVCs when uninstalling the helm chart. | `persistence.existingClaim` | An Existing PVC name for nextcloud volume | `nil` | | `persistence.accessMode` | PVC Access Mode for nextcloud volume | `ReadWriteOnce` | | `persistence.size` | PVC Storage Request for nextcloud volume | `8Gi` | +| `persistence.dataVolumeMount` | Toggle automatic mount of data volume | `true` | | `persistence.nextcloudData.enabled` | Create a second PVC for the data folder in nextcloud | `false` | | `persistence.nextcloudData.annotations` | see `persistence.annotations` | `{}` | | `persistence.nextcloudData.labels` | see `persistence.labels` | `{}` | diff --git a/charts/nextcloud/templates/_helpers.tpl b/charts/nextcloud/templates/_helpers.tpl index 934226e4..a314c451 100644 --- a/charts/nextcloud/templates/_helpers.tpl +++ b/charts/nextcloud/templates/_helpers.tpl @@ -374,7 +374,7 @@ Create volume mounts for the nextcloud container as well as the cron sidecar con - name: nextcloud-data mountPath: {{ .Values.nextcloud.datadir }} subPath: {{ ternary "data" (printf "%s/data" .Values.persistence.nextcloudData.subPath) (empty .Values.persistence.nextcloudData.subPath) }} -{{- else }} +{{- else if .Values.persistence.dataVolumeMount }} - name: nextcloud-main mountPath: {{ .Values.nextcloud.datadir }} subPath: {{ ternary "data" (printf "%s/data" .Values.persistence.subPath) (empty .Values.persistence.subPath) }} diff --git a/charts/nextcloud/templates/deployment.yaml b/charts/nextcloud/templates/deployment.yaml index 2e03dd60..6bd1b6ff 100644 --- a/charts/nextcloud/templates/deployment.yaml +++ b/charts/nextcloud/templates/deployment.yaml @@ -217,7 +217,7 @@ spec: - name: nextcloud-data mountPath: {{ .Values.nextcloud.datadir }} subPath: {{ ternary "data" (printf "%s/data" .Values.persistence.nextcloudData.subPath) (empty .Values.persistence.nextcloudData.subPath) }} - {{- else }} + {{- else if .Values.persistence.dataVolumeMount }} - name: nextcloud-main mountPath: {{ .Values.nextcloud.datadir }} subPath: {{ ternary "data" (printf "%s/data" .Values.persistence.subPath) (empty .Values.persistence.subPath) }} diff --git a/charts/nextcloud/values.yaml b/charts/nextcloud/values.yaml index 9c44fd28..8e0ed820 100644 --- a/charts/nextcloud/values.yaml +++ b/charts/nextcloud/values.yaml @@ -739,6 +739,12 @@ persistence: accessMode: ReadWriteOnce size: 8Gi + # Set this to false if you want to provide your own data directory via + # extraVolumes and extraVolumeMounts. Make sure to mount the folder at at the + # nextcloud.datadir path. + # Ignored if nextcloudData.enabled: true + dataVolumeMount: true + ## Use an additional pvc for the data directory rather than a subpath of the default PVC ## Useful to store data on a different storageClass (e.g. on slower disks) nextcloudData: