harmonize dev prod

This commit is contained in:
leo
2026-02-24 16:36:49 +01:00
parent 1d42dd26ed
commit 543ac20d66
8 changed files with 24 additions and 24 deletions
+8 -8
View File
@@ -40,9 +40,9 @@ DOCKER_GID = $(shell id -g)
DOCKER_USER = $(DOCKER_UID):$(DOCKER_GID)
COMPOSE = DOCKER_USER=$(DOCKER_USER) docker compose
COMPOSE_EXEC = $(COMPOSE) exec
COMPOSE_EXEC_APP = $(COMPOSE_EXEC) app-dev
COMPOSE_EXEC_APP = $(COMPOSE_EXEC) app-development
COMPOSE_RUN = $(COMPOSE) run --rm
COMPOSE_RUN_APP = $(COMPOSE_RUN) app-dev
COMPOSE_RUN_APP = $(COMPOSE_RUN) app-development
COMPOSE_RUN_CROWDIN = $(COMPOSE_RUN) crowdin crowdin
WAIT_DB = @$(COMPOSE_RUN) dockerize -wait tcp://$(DB_HOST):$(DB_PORT) -timeout 60s
@@ -94,8 +94,8 @@ build: ## build the project containers
@$(MAKE) build-frontend
.PHONY: build
build-backend: ## build the app-dev container
@$(COMPOSE) build app-dev
build-backend: ## build the app-development container
@$(COMPOSE) build app-development
.PHONY: build-backend
@@ -107,12 +107,12 @@ down: ## stop and remove containers, networks, images, and volumes
@$(COMPOSE) down
.PHONY: down
logs: ## display app-dev logs (follow mode)
@$(COMPOSE) logs -f app-dev
logs: ## display app-development logs (follow mode)
@$(COMPOSE) logs -f app-development
.PHONY: logs
run-backend: ## start only the backend application and all needed services
@$(COMPOSE) up --force-recreate -d celery-dev
@$(COMPOSE) up --force-recreate -d celery-development
@echo "Wait for postgresql to be up..."
@$(WAIT_DB)
.PHONY: run-backend
@@ -234,7 +234,7 @@ shell: ## open a Django Python shell
# -- Database
dbshell: ## connect to database shell
docker compose exec app-dev python manage.py dbshell
docker compose exec app-development python manage.py dbshell
.PHONY: dbshell
resetdb: FLUSH_ARGS ?=
+1 -1
View File
@@ -89,5 +89,5 @@ function _dc_exec() {
#
# ARGS : django's manage.py command arguments
function _django_manage() {
_dc_run "app-dev" python manage.py "$@"
_dc_run "app-development" python manage.py "$@"
}
+1 -1
View File
@@ -4,5 +4,5 @@ source "$(dirname "${BASH_SOURCE[0]}")/_config.sh"
_dc_run \
-e DJANGO_CONFIGURATION=Test \
app-dev \
app-development \
pytest "$@"
+1 -1
View File
@@ -4,7 +4,7 @@ source "$(dirname "${BASH_SOURCE[0]}")/_config.sh"
_dc_run \
-e DJANGO_CONFIGURATION=Test \
app-dev \
app-development \
python manage.py spectacular \
--api-version 'v1.0' \
--urlconf 'meet.api_urls' \
+10 -10
View File
@@ -55,13 +55,13 @@ services:
entrypoint: >
sh -c "
/usr/bin/mc alias set meet http://minio:9000 meet password &&
/usr/bin/mc admin config set meet notify_webhook:meet-webhook endpoint='http://app-dev:8000/api/v1.0/recordings/storage-hook/' auth_token='Bearer password' &&
/usr/bin/mc admin config set meet notify_webhook:meet-webhook endpoint='http://app-development:8000/api/v1.0/recordings/storage-hook/' auth_token='Bearer password' &&
/usr/bin/mc admin service restart meet --wait --json &&
sleep 15 &&
/usr/bin/mc event add meet/meet-media-storage arn:minio:sqs::meet-webhook:webhook --event put &&
exit 0;"
app-dev:
app-development:
build:
context: .
target: backend-development
@@ -94,7 +94,7 @@ services:
- resource-server
- default
celery-dev:
celery-development:
user: ${DOCKER_USER:-1000}
image: meet:backend-development
command: ["celery", "-A", "meet.celery_app", "worker", "-l", "DEBUG"]
@@ -107,9 +107,9 @@ services:
- ./src/backend:/app
- ./data/static:/data/static
depends_on:
- app-dev
- app-development
app:
app-production:
build:
context: .
target: backend-production
@@ -128,7 +128,7 @@ services:
- livekit
- minio
celery:
celery-production:
user: ${DOCKER_USER:-1000}
image: meet:backend-production
command: ["celery", "-A", "meet.celery_app", "worker", "-l", "INFO"]
@@ -138,7 +138,7 @@ services:
- env.d/development/common
- env.d/development/postgresql
depends_on:
- app
- app-production
nginx:
image: nginx:1.25
@@ -249,7 +249,7 @@ services:
ports:
- "6379:6379"
app-summary-dev:
app-summary-development:
build:
context: src/summary
target: summary-development
@@ -278,7 +278,7 @@ services:
- ./src/summary:/app
depends_on:
- redis-summary
- app-summary-dev
- app-summary-development
- minio
develop:
watch:
@@ -298,7 +298,7 @@ services:
- ./src/summary:/app
depends_on:
- redis-summary
- app-summary-dev
- app-summary-development
- minio
develop:
watch:
+1 -1
View File
@@ -7,4 +7,4 @@ keys:
webhook:
api_key: devkey
urls:
- http://app-dev:8000/api/v1.0/rooms/webhooks-livekit/
- http://app-development:8000/api/v1.0/rooms/webhooks-livekit/
+1 -1
View File
@@ -61,7 +61,7 @@ ALLOW_UNREGISTERED_ROOMS=False
RECORDING_ENABLE=True
RECORDING_STORAGE_EVENT_ENABLE=True
RECORDING_STORAGE_EVENT_TOKEN=password
SUMMARY_SERVICE_ENDPOINT=http://app-summary-dev:8000/api/v1/tasks/
SUMMARY_SERVICE_ENDPOINT=http://app-summary-development:8000/api/v1/tasks/
SUMMARY_SERVICE_API_TOKEN=password
RECORDING_DOWNLOAD_BASE_URL=http://localhost:3000/recording
+1 -1
View File
@@ -1,4 +1,4 @@
APP_NAME="meet-app-summary-dev"
APP_NAME="meet-app-summary-development"
APP_API_TOKEN="password"
AWS_STORAGE_BUCKET_NAME="http://meet-media-storage"