-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
99 lines (92 loc) · 2.02 KB
/
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
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
97
98
99
version: '3'
services:
backend:
build:
context: "./apps/backend-microservice"
dockerfile: "Dockerfile"
args:
UID: "${UID}"
GID: "${GID}"
working_dir: "/app"
restart: "unless-stopped"
environment:
NODE_ENV: "development"
HOST: "0.0.0.0"
PORT: "3000"
DATABASE_URL: $DATABASE_URL
AI_URL: $AI_URL
JWT_SECRET: $JWT_SECRET
STATUS_SECRET_KEY: $STATUS_SECRET_KEY
expose:
- "3000"
volumes:
- "./apps/backend-microservice:/app:delegated"
command: "bash -c 'yarn install --frozen-lockfile && yarn prisma generate && yarn prisma migrate dev && yarn start:dev'"
networks:
- "app"
depends_on:
- "mysql"
frontend:
build:
context: "./apps/client"
dockerfile: "Dockerfile"
args:
UID: "${UID}"
GID: "${GID}"
working_dir: "/app"
restart: "unless-stopped"
expose:
- "8080"
volumes:
- "./apps/client:/app:delegated"
command: "bash -c 'npm install && npm run dev'"
networks:
- "app"
ai:
build:
context: "./apps/ai"
dockerfile: "Dockerfile"
args:
UID: "${UID}"
GID: "${GID}"
working_dir: "/app"
restart: "unless-stopped"
expose:
- "2137"
volumes:
- "./apps/ai:/app:delegated"
command: "bash -c 'python main.py'"
networks:
- "app"
nginx:
image: "nginx:1.25"
volumes:
- "./nginx/default.conf:/etc/nginx/conf.d/default.conf"
- "./nginx/app.crt:/etc/nginx/cert/app.crt"
- "./nginx/app.key:/etc/nginx/cert/app.key"
ports:
- "80:80"
- "443:443"
networks:
- "app"
depends_on:
- "backend"
- "frontend"
mysql:
image: "mysql:8"
restart: "unless-stopped"
environment:
MYSQL_DATABASE: "app"
MYSQL_ROOT_PASSWORD: "root"
ports:
- "3306:3306"
expose:
- "3306"
volumes:
- "mysql:/var/lib/mysql"
networks:
- "app"
networks:
app: null
volumes:
mysql: null