From 0027c24306f097ba4a44d6d7b50f3b55a7d220c1 Mon Sep 17 00:00:00 2001 From: chris Date: Wed, 5 Oct 2022 22:28:31 +0000 Subject: [PATCH] Update 'README.md' --- README.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/README.md b/README.md index 3c630f4..f8b5330 100644 --- a/README.md +++ b/README.md @@ -409,6 +409,20 @@ Type=oneshot ExecStart=/usr/bin/certbot renew --quiet --agree-tos --deploy-hook "docker exec scarif_nginx_1 nginx -s reload && cp /etc/letsencrypt/live/scarif.space/fullchain.pem /opt/ssl/scarif.space.crt && cp /etc/letsencrypt/live/scarif.space/private.pem /opt/ssl/scarif.space.key" ``` +## upgrading +Nextcloud is the annoying one here. Unless you want to take the risk, you need to upgrade to each major version, incrementally. +You can do this by changing the base image in the `nextcloud/DockerFile` file to `nextcloud:{version}-fpm-alpine`. +Once you have done that you can upgrade all the images: +``` +sudo docker-compose pull # to upgrade the images +sudo docker-compose pull nextcloud:{version}-fpm-alpine # because docker-compose can't tell that it is used by the nextcloud image +sudo docker-compose down # to destroy all the existing containers +sudo docker-compose up --force-recreate --build -d # to rebuild all the containers with the newest images +sudo docker-compose exec -u 82 -it nextcloud php /var/www/html/occ upgrade -vvv # to run the upgrade script +sudo docker-compose exec -u 82 -it nextcloud php /var/www/html/occ maintenance:mode --off # to turn the site back on +``` +Provided that all went smoothly, you should do it all again if there are more major versions for nextcloud. + ## Troubleshooting - Sometimes the `bootstrap.sh` script would fail. This was because the system needed to be restarted after upgrading packages. Instead I separated out the `bootstrap.sh` file. - Docker compose doesn't work? Make sure docker is running.