Features: 1) Add support for specifying build context in all service definitions of docker-compose.yml;

Fixes: 1) Correct build key structure for Dockerfile definitions across services;

Extra: Code cleanup for consistency in unused storefront service comments;
This commit is contained in:
Egor Pavlovich Gorbunov 2025-05-26 15:59:49 +03:00
parent f16c03d2a6
commit 165f7be0ae

View file

@ -7,7 +7,9 @@ x-logging:
services:
app:
container_name: app
build: Dockerfile.app
build:
- dockerfile: Dockerfile.app
- context: .
restart: always
command: >
sh -c "poetry run python manage.py await_services &&
@ -42,7 +44,9 @@ services:
worker:
container_name: worker
build: Dockerfile.app
build:
- dockerfile: Dockerfile.app
- context: .
restart: always
command: >
sh -c "poetry run celery -A evibes worker --loglevel=info --concurrency=4 --autoscale=4,2 --max-tasks-per-child=100 --max-memory-per-child=512000 --soft-time-limit=10800 --time-limit=21600"
@ -64,7 +68,9 @@ services:
beat:
container_name: beat
build: Dockerfile.app
build:
- dockerfile: Dockerfile.app
- context: .
restart: always
command: sh -c "poetry run celery -A evibes beat -l info --scheduler django_celery_beat.schedulers:DatabaseScheduler"
volumes:
@ -106,7 +112,9 @@ services:
flower:
container_name: flower
build: Dockerfile.app
build:
- dockerfile: Dockerfile.app
- context: .
restart: always
command: sh -c "poetry run celery -A evibes --broker=$CELERY_BROKER_URL flower --address=0.0.0.0 --port=5555 --basic_auth=$FLOWER_USER:$FLOWER_PASSWORD"
depends_on:
@ -127,7 +135,9 @@ services:
# storefront: # TODO complete the service for future "storefront" Vite-Vue3 base storefront app
# container_name: storefront
# build: Dockerfile.storefront
# build:
# - dockerfile: Dockerfile.storefront
# - context: ./storefront
# logging: *default-logging
volumes: