diff --git a/docker-compose.yml b/docker-compose.yml index 79b5943..53ae43b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,5 +1,3 @@ -version: '3.8' - # Coolify & Production Ready Docker Compose Configuration # Traefik in Coolify automatically routes traffic to the 'frontend' service on port 80 via expose. # Host port bindings (ports) are omitted to avoid host port 80 conflicts with Traefik. @@ -17,18 +15,17 @@ services: - "5432" restart: unless-stopped healthcheck: - test: ["CMD-SHELL", "pg_isready -U ${POSTGRES_USER:-shiftplan_user} -d ${POSTGRES_DB:-shiftplan_db}"] - interval: 5s - timeout: 5s - retries: 5 + test: ["CMD-SHELL", "pg_isready"] + interval: 3s + timeout: 3s + retries: 10 backend: build: context: ./backend dockerfile: Dockerfile command: > - sh -c "python manage.py makemigrations --noinput && - python manage.py migrate --noinput && + sh -c "python manage.py migrate --noinput && python manage.py collectstatic --noinput && python manage.py create_admin && gunicorn --bind 0.0.0.0:8000 --workers 3 shiftplan_backend.wsgi:application"