-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
79 lines (73 loc) · 2.01 KB
/
docker-compose.yml
File metadata and controls
79 lines (73 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
services:
web:
build: .
volumes:
- ./agate:/agate
working_dir: /agate
depends_on:
db_service:
condition: service_healthy
rabbitmq_service:
condition: service_healthy
environment:
- SECRET_KEY=zbfj^u2!7-7(k6u0crkz#@v+=vd8+iyu+)9u+v^$8p5fon1_+3
- HOST_NAME=127.0.0.1
- DATABASE_NAME=db_service_test
- DATABASE_USER=postgres
- DATABASE_PASSWORD=postgres
- DATABASE_HOST=db_service
- ONYX_DOMAIN=http://phonyx_service:80
- CORS_ALLOWED_ORIGINS=http://localhost:5173/
command: >
bash -c "python manage.py makemigrations &&
python manage.py migrate &&
python manage.py check &&
python manage.py runserver 0.0.0.0:8000"
ports:
- 8001:8000
phonyx_service:
image: python:3.9
environment:
- TOKEN=57f6bf4c44231155def6ad9e8cf072b71c2a782fd228686df94cf195b08ce7cc
volumes:
- ./phonyx:/phonyx
working_dir: /phonyx
command: >
bash -c "pip install --no-cache-dir --upgrade fastapi[standard] &&
fastapi run main.py --port 80"
ports:
- 8002:80
rabbitmq_service:
image: rabbitmq:3-management-alpine
environment:
- RABBITMQ_DEFAULT_USER=guest
- RABBITMQ_DEFAULT_PASS=guest
ports:
- 5672:5672
- 15672:15672
volumes:
- rabbitmq_service_data:/var/lib/rabbitmq/
- rabbitmq_service_log:/var/log/rabbitmq
healthcheck:
test: [ "CMD", "nc", "-z", "localhost", "5672" ]
interval: 10s
timeout: 10s
retries: 5
db_service:
image: postgres:13-alpine
user: postgres
volumes:
- db_service_data:/var/lib/postgresql/data/
environment:
- POSTGRES_DB=db_service_test
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
healthcheck:
test: ["CMD-SHELL", "pg_isready -U postgres"]
interval: 1s
timeout: 1s
retries: 5
volumes:
rabbitmq_service_data:
rabbitmq_service_log:
db_service_data: