-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
96 lines (90 loc) · 2.04 KB
/
docker-compose.yml
File metadata and controls
96 lines (90 loc) · 2.04 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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
version: "3"
name: "coco"
services:
frontend:
image: styughjvbn/coco_frontend
container_name: coco_frontend
build:
context: ./coco/
dockerfile: Dockerfile
ports:
- "80:80"
stdin_open: true
networks:
- coco_proxy
mysql:
image: styughjvbn/coco_db
container_name: coco_db
platform: linux/x86_64
build: ./mysql/
volumes:
- mysql:/var/lib/mysql
ports: #host 3307과 컨테이너의 3306포트 연결
- "3307:3306"
env_file: # 설정에 필요한 환경변수
- ./envs/mysql.env
tty: true
restart: always
networks:
- coco_network
fastapi:
image: styughjvbn/coco_backend
depends_on:
- mysql
container_name: coco_backend
platform: linux/x86_64
build: ./
restart: always
tty: true
volumes: # static 볼륨과 연결
- static:/static
- type: bind
source: ./plugin
target: /home/app/plugin
volume:
nocopy: false
ports: #host 1000과 컨테이너의 8000포트 연결
- 1000:8000
env_file:
- ./envs/common.env
- ./envs/backend.env
networks:
- coco_network
- coco_proxy
# celery broker
redis:
image: styughjvbn/coco_mq
container_name: coco_mq
volumes:
- mq:/data
tty: true
networks:
- coco_network
#celery worker
celery_worker:
image: styughjvbn/coco_worker
container_name: coco_worker
depends_on:
- redis
build:
context: ./
dockerfile: celeryworker.dockerfile
volumes: # static 볼륨과 연결
- static:/static
env_file:
- ./envs/common.env
- ./envs/celeryworker.env
privileged: true # isolate의 sandbox마다 컴퓨터 자원 제한을 하기 위해 필요한 설정값
networks:
- coco_network
volumes: # task의 test case와 같이 유지되는 파일들을 저장하는 볼륨
static:
mysql:
mq:
networks:
coco_network:
name: coco_network
attachable: true
coco_proxy:
name: coco_proxy
attachable: true