From 5ea9ed3494c36ce25a3d6e470a36a44406ed934a Mon Sep 17 00:00:00 2001 From: jon r Date: Tue, 25 Feb 2025 01:12:19 +0100 Subject: [PATCH] fix(settings/local): do not force by default, but specify explicitly Adds tini as PID 1 to Django containers for them to react to signals. (init: true) --- .env.example | 1 + api/config/settings/local.py | 2 +- compose/app.django.yml | 8 ++------ 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.env.example b/.env.example index 71c1bac44..97339446d 100644 --- a/.env.example +++ b/.env.example @@ -2,6 +2,7 @@ COMPOSE_BAKE=true # api + celeryworker DEBUG=True +FORCE=True DEFAULT_FROM_EMAIL=hello@funkwhale.test FUNKWHALE_DOMAIN=funkwhale.test diff --git a/api/config/settings/local.py b/api/config/settings/local.py index b1674f46d..5e85ff5cc 100644 --- a/api/config/settings/local.py +++ b/api/config/settings/local.py @@ -154,4 +154,4 @@ REST_FRAMEWORK.update( ) # allows makemigrations and superuser creation -FORCE = env("FORCE", default=1) +FORCE = env("FORCE", default=0) diff --git a/compose/app.django.yml b/compose/app.django.yml index 74423d1dc..7c1ec7a7a 100644 --- a/compose/app.django.yml +++ b/compose/app.django.yml @@ -1,22 +1,18 @@ x-django: &django image: funkwhale-api + init: true networks: - internal volumes: - ../api:/app - - ../.env:/app/.env - "${MUSIC_DIRECTORY_SERVE_PATH:-../.state/music}:/music:ro" - "../.state/plugins:/srv/funkwhale/plugins" - "../.state/staticfiles:/staticfiles" - "../.state/media:/protected/media" - "../.state/${COMPOSE_PROJECT_NAME:-funkwhale}/media:/data/media" - depends_on: - postgres: - condition: service_healthy - redis: - condition: service_healthy environment: - DEBUG + - FORCE - DEFAULT_FROM_EMAIL - DJANGO_SETTINGS_MODULE