Calcom Docker update from version 4.5 not possible
i have 2 Calcom Docker Container with the version 4.5 running. If i try to update to a newer version, calcom is not accessible anymore. I got for one second an 500 error and than a blank screen.
docker ps shows the following:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 058bd3530d97 calcom.docker.scarf.sh/calcom/cal.com "docker-entrypoint.s…" 4 minutes ago Up 4 minutes (unhealthy) 0.0.0.0:3000->3000/tcp, :::3000->3000/tcp calcom_calcom_1 03c9bae547bd postgres "docker-entrypoint.s…" 4 minutes ago Restarting (1) 29 seconds ago
is there any changes i have to made to update to a newer version as 4.5?
i think it is a problem with the database version.
I changed in the docker-compose.yml file the following line:
- database-data:/var/lib/postgresql/data/
to:
- database-data:/var/lib/postgresql@16/data/
and then calcom starts with a fresh environment. But i loose all my configuration so this is no option.
database | database | PostgreSQL Database directory appears to contain a database; Skipping initialization database | database | 2024-11-06 09:28:02.077 UTC [1] FATAL: database files are incompatible with server database | 2024-11-06 09:28:02.077 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 16, which is not compatible with this version 17.0 (Debian 17.0-1.pgdg120+1).
I just ran into this as well. Is there any update on this? How do we upgrade without breaking the PostgreSQL?
Hi Speedy059, the problem is that PostgreSQL upgrade from Version 16 to 17. This is depending on the first installation date. We have 2 options: a) you upgrade your Database manually from 16 to 17. b) you change your docker-composer.yml in the following part to stay on PostgreSQL Version 16:
services:
database:
container_name: database
image: postgres:16
restart: always
I stay on the old PosgreSQL Version and can update calcom at the moment. But in future we have to upgrade the database manually. Maybee this helps: https://hahouari.medium.com/upgrade-from-postgresql-16-x-to-17-0-in-docker-compose-00d7417fd555
The upgrade in major database versions may not always be automated. We'll try to tag specific versions in the future. In the meantime, the calcom/cal.com repo may be a better place for support on issues like these