Open urbaman opened 2 years ago
Finally working, with a proper DNS added and working. I had to add the DNS and a Traefik IngressRoute to use it.
Opening a new issue because now Nexcloud asks me if I'm reinstalling, and I'm actually not, right?
Hey urbaman!
Initialization takes a long time and I had similar issues.
If you still have probs, try first init with cronjob disabled and set liveness, readiness and startup probes to 'false'.
Watch the logs of the nextcloud container for init and install to finish.
Adjust your values.yml:
Then try to helm upgrade your installation. If that doesn't work, Helm uninstall an then install again, of course without deleting persistence.
Hope that helps.
Greetz
In my case, startupProbe.enabled
is set to false
by default. This causes the liveness and readiness probes to run too soon, which causes the container to be restarted before it can actually do the first time setup. The logs don't show any errors because the container is being restarted externally, not because the container itself had a problem. Thus why you just see the initializing message endlessly.
The fix for me was to set startupProbe.enabled
to true
, which allows the container to initialize before the readiness and liveness probes kick off and start rebooting it. If your cluster is slower, you may need to adjust the values under the startupProbe
configuration to give it more time to start up.
The startup probe needs to be enabled by default and modified from using an httpGet to running a command that:
For me the rsync step took 3 minutes 30 seconds.
The alternative would just be to keep restarting and restarting the rync over and over again till the rsync has a chance to finally complete. Setting the startup probe with an initial delay of 4 minutes works ... but we don't really want to change that for first run then go back and change it everytime afterwards.
Note: 4 minutes worked, but it wasn't enough to complete the initial installation, 4 minutes was enough for the rsync to complete but it crashed and restarted 10 more times before the readiness and liveliness probes were happy ... I'm betting the initialization wasn't complete.)
A note in the log that its performing its first time initialization and that it may take a long time, up to 5 minutes, would be good to have in the logs as admins check to see why its taking so long.
It's not apparent to me, why nextcloud copies application code in the persistent storage location:
/mnt/nfs/services/nextcloud-nextcloud/html/3rdparty/aws/aws-sdk-php
In my eyes, this is not a valid approach for containerized applications.
My current configuration:
persistence:
enabled: true
storageClass: nfs
accessMode: ReadWriteMany
I'm actually not sure if that's something we're doing in the helm chart or if this is being done by something in the docker container, which would be a nextcloud/docker issue 🤔 I haven't had a moment to check though.
That's how the docker image works. I also don't like but afaik there is no way around it due to the architecture of Nextcloud (which is not very container friendly)
The way the chart currently works, thankfully, means that using a properly immutable image is possible. I did fork the nextcloud image and build a POC image which can run and perform basic upgrades without any rsyncing: https://github.com/thefirstofthe300/nextcloud-docker
The image isn't fully tested so there's likely some pieces that are broken, but that's mostly a matter of adding things back that I may have not reworked properly after gutting the install/upgrade logic. I welcome testing of the image, but please DON'T use it on production data yet.
In the name of testing, I do have a PR open to add removing the /var/www
and /var/www/html
mounts: #496
The lack of rsyncing almost certainly breaks folks using Docker Compose so submitting the image upstream may not be the easiest.
Hi,
I'm trying to setup nextcloud through the Helm chart, backed by some PVCs on shared glusterfs. Glusterfs works, as I see all of the paths (nextcloud, mariadb, redis master/replica) getting written. Thing is that the nextcloud pod's logs keeps staying in the "initializing nextcloud" part for more than 7 minutes, with the probes getting faults and restarting the pod.
Also, if I enable croinjob, it fails with something liek "wrong image" message.
Here's my values.yaml file: