-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
49 lines (47 loc) · 900 Bytes
/
docker-compose.yml
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
version: '3'
volumes:
viole_db_dco: {}
services:
db:
image: mysql:5.7
volumes:
- viole_db_dco:/var/lib/mysql/data
restart: always
expose:
- 3306
ports:
- 3307:3306
environment:
MYSQL_ROOT_PASSWORD: password
MYSQL_DATABASE: viole
backend:
build:
context: .
dockerfile: Dockerfile-compose-backend
environment:
- ENV=dev
- DB_URL=mysql://root:password@${viole-db}:3306/viole
expose:
- 8000
ports:
- "8000:8000"
command:
- bash
- -c
- |
uvicorn main:app --host 0.0.0.0 --reload
volumes:
- ./:/app/
scheduler:
build:
context: .
dockerfile: Dockerfile-compose-scheduler
environment:
- HOST=http://${viole-backend}:8000
volumes:
- ./:/app/
command:
- bash
- -c
- |
python scheduler.py