I am currently using ālatestā as version for the NC container.
I pulled the new NC version hoping that everything would continue to work without any other particular update procedure. is that a reasonable expectation?
after pulling my NC is not workingā¦ its complaining about db credentials.
thatās the wrong place. nothing that is changed during operation is allowed inside a container.
if you donāt put /var/www/html in a volume all your changes to your nextcloud will be gone with that container.
example:
that indicates (to me) that in the new container the initial setup didnāt run. and you have a strange state. you have no config.php but you have a postgres database. so the initial setup fails because it canāt create the database. as far as i remember that is not cover by the script.
yes, I have a volume for /var/www/html
then i am mounting a custom.config.php with mail settings only.
everything else is provided by the pulled image.
I think I have followed the examples /documentation properly
a script is doing this for you. when you look at the entrypoint.sh script of the nc docker image youāll see that the update is done in that script (if needed). the script copies the nextcloud php files from /usr/src/nextcloud/ to /var/www/html/ with an rsync command.
in the file upgrade.exclude you can see what is not synced because these are user created/modified files. and therefore should not be over written. in line 49 the script checks if the directories exists and creates them if needed.
that looks bad. if config.php isnāt writeable by nextcloud you canāt do any changes to your nextcloud (that are store in the config.php) that includes update to another version.
hope that helps you find out the right configuration.
I am not getting it to work
I tried to stop mounting any custom settings and trigger the update script again, by modifying the versions.php and leaving it as 14.0.0
still keeps trying to connect to the database with a default username ignoring the environment variable. Unfortunately I have very little time to put on this.
I find very troubling that my data volume includes, basically, the whole nextcloud PHP code. this is not the idea behind the volumes. Being able to replace the container image while keeping the data is a key benefit of docker.
I am going to wipe the data volume and get a fresh install, as I have no data of value, I am mostly testing the viability of replacing my Synology by Nextcloud.