2023-12-02 19:08:21 +03:00
|
|
|
version: "3.8"
|
2023-06-04 00:12:42 +03:00
|
|
|
|
|
|
|
services:
|
2023-07-17 09:57:27 +03:00
|
|
|
backend-core:
|
2023-11-14 12:03:25 +03:00
|
|
|
image: backend-base
|
2023-12-02 19:08:21 +03:00
|
|
|
pull_policy: never
|
2023-06-04 00:12:42 +03:00
|
|
|
env_file:
|
2023-12-02 19:08:21 +03:00
|
|
|
- .env
|
2023-06-04 00:12:42 +03:00
|
|
|
build:
|
2023-08-19 14:32:16 +03:00
|
|
|
context: backend
|
2023-12-05 02:26:06 +03:00
|
|
|
dockerfile: Dockerfile.dev
|
2023-10-09 16:23:13 +03:00
|
|
|
args:
|
|
|
|
- DEV_MODE=true
|
2023-07-17 09:57:27 +03:00
|
|
|
container_name: backend-core
|
2023-06-04 00:12:42 +03:00
|
|
|
volumes:
|
2023-08-19 14:32:16 +03:00
|
|
|
- ./backend/:/code/
|
2024-01-03 23:53:37 +03:00
|
|
|
command:
|
2023-12-02 19:08:21 +03:00
|
|
|
- "uvicorn"
|
|
|
|
- "main:app"
|
2023-12-02 20:08:22 +03:00
|
|
|
- "--reload"
|
2023-12-02 19:08:21 +03:00
|
|
|
- "--host"
|
|
|
|
- "0.0.0.0"
|
|
|
|
- "--port"
|
|
|
|
- "5050"
|
|
|
|
- "--workers"
|
2024-01-21 00:51:03 +03:00
|
|
|
- "6"
|
2024-01-03 23:53:37 +03:00
|
|
|
restart: always
|
|
|
|
|
2023-09-14 18:23:17 +03:00
|
|
|
ports:
|
|
|
|
- 5050:5050
|
2023-10-09 16:23:13 +03:00
|
|
|
- 5678:5678 # debug port
|
|
|
|
|
2023-09-14 18:23:17 +03:00
|
|
|
redis:
|
2024-01-04 16:00:18 +03:00
|
|
|
image: redis:latest@sha256:a7cee7c8178ff9b5297cb109e6240f5072cdaaafd775ce6b586c3c704b06458e
|
2023-09-14 18:23:17 +03:00
|
|
|
container_name: redis
|
2023-12-02 19:08:21 +03:00
|
|
|
restart: always
|
2023-09-14 18:23:17 +03:00
|
|
|
ports:
|
|
|
|
- 6379:6379
|
2023-10-09 16:23:13 +03:00
|
|
|
|
2023-09-14 18:23:17 +03:00
|
|
|
worker:
|
2023-12-02 19:08:21 +03:00
|
|
|
pull_policy: never
|
2023-11-14 12:03:25 +03:00
|
|
|
image: backend-base
|
2023-08-18 11:18:29 +03:00
|
|
|
env_file:
|
2023-12-02 19:08:21 +03:00
|
|
|
- .env
|
2023-08-18 11:18:29 +03:00
|
|
|
build:
|
2023-08-19 14:32:16 +03:00
|
|
|
context: backend
|
2023-12-02 19:08:21 +03:00
|
|
|
dockerfile: Dockerfile
|
2023-09-14 18:23:17 +03:00
|
|
|
container_name: worker
|
|
|
|
command: celery -A celery_worker worker -l info
|
2023-12-02 19:08:21 +03:00
|
|
|
restart: always
|
|
|
|
depends_on:
|
|
|
|
- redis
|
|
|
|
|
|
|
|
beat:
|
|
|
|
image: backend-base
|
|
|
|
pull_policy: never
|
|
|
|
env_file:
|
|
|
|
- .env
|
|
|
|
build:
|
|
|
|
context: backend
|
|
|
|
dockerfile: Dockerfile
|
|
|
|
container_name: beat
|
|
|
|
command: celery -A celery_worker beat -l info
|
|
|
|
restart: always
|
2023-09-14 18:23:17 +03:00
|
|
|
depends_on:
|
|
|
|
- redis
|
2023-10-09 16:23:13 +03:00
|
|
|
|
2023-09-14 18:23:17 +03:00
|
|
|
flower:
|
2023-11-14 12:03:25 +03:00
|
|
|
image: backend-base
|
2023-12-02 19:08:21 +03:00
|
|
|
pull_policy: never
|
2023-08-18 11:18:29 +03:00
|
|
|
env_file:
|
2023-12-02 19:08:21 +03:00
|
|
|
- .env
|
2023-08-18 11:18:29 +03:00
|
|
|
build:
|
2023-08-19 14:32:16 +03:00
|
|
|
context: backend
|
2023-12-02 19:08:21 +03:00
|
|
|
dockerfile: Dockerfile
|
2023-09-14 18:23:17 +03:00
|
|
|
container_name: flower
|
|
|
|
command: celery -A celery_worker flower -l info --port=5555
|
2023-12-02 19:08:21 +03:00
|
|
|
restart: always
|
2023-09-14 18:23:17 +03:00
|
|
|
depends_on:
|
|
|
|
- redis
|
|
|
|
- worker
|
2023-12-02 19:08:21 +03:00
|
|
|
- beat
|
2023-09-14 18:23:17 +03:00
|
|
|
ports:
|
|
|
|
- 5555:5555
|