I do run Owncloud on a Raspi 5 in a docker environment with Portainer. Currently I am running version 10.15. Since 10.16 is out for quite a while I’d like to upgrade. However, I am not able to do that successfully, and I have no clue what I am doing wrong.
Installing with Docker :: Documentation for ownCloud (A Kiteworks Company) describes the process. However, that does not work for me. The container owncloud_server does not start properly. The log shows it is waiting for MySQL:
Creating volume folders…
Creating hook folders…
Waiting for MySQL…
services aren’t ready in 3m0s
Database didn’t come up in time!
Creating volume folders…
Creating hook folders…
Waiting for MySQL…
services aren’t ready in 3m0s
Database didn’t come up in time!
Creating volume folders…
Creating hook folders…
Waiting for MySQL…
services aren’t ready in 3m0s
Database didn’t come up in time!
Creating volume folders…
Creating hook folders…
Waiting for MySQL…
This is my YML:
services:
owncloud:
image: owncloud/server:${OWNCLOUD_VERSION}
container_name: owncloud_server
restart: always
ports:
- ${HTTP_PORT}:8080
depends_on:
- mariadb
- redis
environment:
- OWNCLOUD_DOMAIN=${OWNCLOUD_DOMAIN}
- OWNCLOUD_TRUSTED_DOMAINS=${OWNCLOUD_TRUSTED_DOMAINS}
- OWNCLOUD_DB_TYPE=mysql
- OWNCLOUD_DB_NAME=owncloud
- OWNCLOUD_DB_USERNAME=owncloud
- OWNCLOUD_DB_PASSWORD=owncloud
- OWNCLOUD_DB_HOST=mariadb
- OWNCLOUD_ADMIN_USERNAME=${ADMIN_USERNAME}
- OWNCLOUD_ADMIN_PASSWORD=${ADMIN_PASSWORD}
- OWNCLOUD_MYSQL_UTF8MB4=true
- OWNCLOUD_REDIS_ENABLED=true
- OWNCLOUD_REDIS_HOST=redis
healthcheck:
test: ["CMD", "/usr/bin/healthcheck"]
interval: 30s
timeout: 10s
retries: 5
volumes:
- ${OWNCLOUD_FILES_LOCATION}:/mnt/data
- ${OWNCLOUD_USER_ALEX_FILES_LOCATION}:/mnt/data/files/Alex
- ${OWNCLOUD_USER_ANTJE_FILES_LOCATION}:/mnt/data/files/Antje
- ${OWNCLOUD_USER_VIKA_FILES_LOCATION}:/mnt/data/files/Vika
- ${OWNCLOUD_USER_KUECHENTABLET_FILES_LOCATION}:/mnt/data/files/Kuechentablet
mariadb:
image: mariadb:10.11 # minimum required ownCloud version is 10.9
container_name: owncloud_mariadb
restart: always
environment:
- MYSQL_ROOT_PASSWORD=owncloud
- MYSQL_USER=owncloud
- MYSQL_PASSWORD=owncloud
- MYSQL_DATABASE=owncloud
- MARIADB_AUTO_UPGRADE=1
command: ["--max-allowed-packet=128M", "--innodb-log-file-size=64M"]
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-u", "root", "--password=owncloud"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- ./mysql:/var/lib/mysql
redis:
image: redis:6
container_name: owncloud_redis
restart: always
command: ["--databases", "1"]
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 5s
retries: 5
volumes:
- ./redis:/data
And this is my ENV file:
OWNCLOUD_VERSION=10.15
OWNCLOUD_DOMAIN=192.168.2.222:8080
OWNCLOUD_TRUSTED_DOMAINS=192.168.2.222
ADMIN_USERNAME=admin
ADMIN_PASSWORD=<password>
HTTP_PORT=8080
OWNCLOUD_FILES_LOCATION=/data/DockerVolumes/OwnCloud
OWNCLOUD_USER_ALEX_FILES_LOCATION=/mnt/nas_raid/OwnCloud/Files/Alex
OWNCLOUD_USER_ANTJE_FILES_LOCATION=/mnt/nas_raid/OwnCloud/Files/Antje
OWNCLOUD_USER_VIKA_FILES_LOCATION=/mnt/nas_raid/OwnCloud/Files/Vika
OWNCLOUD_USER_KUECHENTABLET_FILES_LOCATION=/mnt/nas_raid/OwnCloud/Files/Kuechentablet
I attempted the following:
In Portainer I opened a shell in the container owncloud_server and entered
occ maintenance:mode --on
This works, I see the respective warning when browsing to http://192.168.2.222:8080/login. Next, I open the “stack details” page for owncloud, Klick on “Editor”, expand “Environment variables” and change OWNCLOUD_VERSION to 10.16. After that I click on “update the stack”, enable “Re-pull image and redeploy” and click on “update”.
After that owncloud_server never comes up, eternally waiting for MySQL.
What am I doing wrong?