When a new version of ownCloud gets released, you should update your instance. To do so, follow these simple steps:
- Go to your docker directory where your
.yamland.envfiles exist. - Put ownCloud into maintenance mode with the following command:
docker-compose exec owncloud occ maintenance:mode --on - Create a backup of the database in case something goes wrong during the upgrade process, using the following command:
docker-compose exec mariadb \/usr/bin/mysqldump \-u root \--password=owncloud \--single-transaction \owncloud > owncloud_$(date +%Y%m%d).sql
You need to adjust the password and database name if you have changed it in your deployment. - Shutdown the containers:
docker-compose down - Update the version number of ownCloud in your
.envfile. You can use sed for it, as in the following example:
Make sure that you adjust the example to match your installation.sed -i \'s/^OWNCLOUD_VERSION=.*$/OWNCLOUD_VERSION=10.13.3/' .env - View the file to ensure the change has been implemented:
cat .env - Start your docker instance again.
docker-compose up -d
Now you should have the current ownCloud running withdocker-compose. Note that the container will automatically runocc upgradewhen starting up. If you notice the container starting over and over again, you can check the update log with the following command:docker-compose logs --timestamp owncloud - If all went well, end maintenance mode:
docker-compose exec owncloud occ maintenance:mode --off
This is a copy of the below page:
https://doc.owncloud.com/server/10.13/admin_manual/installation/docker/#upgrading-owncloud-on-docker