-
Notifications
You must be signed in to change notification settings - Fork 269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
volumeMount and NFS mount clash when trying to use NFS for primary data storage #552
Comments
I've also been trying to get this to work. As you alluded to, it's because the value of helm/charts/nextcloud/templates/deployment.yaml Lines 222 to 230 in 36118d0
I expect changes would be needed to allow for this common(?) use-case as it does not appear to be configurable in any way. |
@bcbrookman or @miguemely I'd like to understand this a bit better. Would setting the helm/charts/nextcloud/values.yaml Lines 431 to 438 in cf19396
And here's the pesistence docs we have right now. Please let me know if you think this won't work, and if not, what you'd like to see done instead. As this is a community maintained chart, we're always open to pull requests to improve the chart 💙 |
I was able to get this working by using an existing claim: pvc.yaml ---
apiVersion: v1
kind: PersistentVolume
metadata:
name: nextcloud-pv
spec:
storageClassName: nextcloud-nfs
capacity:
storage: 300Gi
accessModes:
- ReadWriteMany
persistentVolumeReclaimPolicy: Retain
nfs:
path: /mnt/tank/cloud
server: ${SECRET_TRUENAS_IP}
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: nextcloud-pvc
spec:
storageClassName: nextcloud-nfs
accessModes:
- ReadWriteMany
resources:
requests:
storage: 300Gi helmrelease.yaml nextcloud:
...
datadir: /var/www/data
...
persistence:
enabled: true
existingClaim: *app
nextcloudData:
enabled: true
existingClaim: nextcloud-pvc Notes:
Afterwards I refreshed the page and everything came up fine. |
@Heavybullets8 Not understanding you here, Did you apply those files before the helm chart or? The other problem there is the subpath of |
How exactly would this work? Would we provide the existing pvc in existingClaim?? |
Actually...ignore me. I just put two and two together (once I relooked at #552 (comment)) Let me give that a go... |
Thanks for the responses! I did see |
Happy to help :) Please let me know if everyone is all set, and if not, how we can help further 🙏 |
Could be related to #264 and #531
Originally posted by @miguemely in #264 (comment)
So I'm trying to deploy this helm chart to replace my old install that uses NFS.
On the old install, it mounts a NFS share to /ncdata (Nextcloud Data Directory). This is what is defined in the Nextcloud config as its "Data Directory".
Within the helm values, I defined the following:
nextcloud.datadir: /ncdata
nextcloud.extraVolumes:
The error I get is
Deployment.apps "nextcloud" is invalid: [spec.template.spec.containers[0].volumeMounts[7].mountPath: Invalid value: "/ncdata": must be unique, spec.template.spec.containers[1].volumeMounts[8].mountPath: Invalid value: "/ncdata": must be unique, spec.template.spec.containers[2].volumeMounts[7].mountPath: Invalid value: "/ncdata": must be unique, spec.template.spec.containers[3].volumeMounts[0].name: Not found: "nextcloud-data"
I'm noticing that when I do a dry run, it creates a volumeMount for nextcloud-main.
Is there a way to tell it not to use/create that mountPath, and instead use the one I specified for NFS?
The text was updated successfully, but these errors were encountered: