-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.prod.yml
More file actions
75 lines (68 loc) · 1.59 KB
/
docker-compose.prod.yml
File metadata and controls
75 lines (68 loc) · 1.59 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
version: '3.8'
services:
db:
image: mariadb:10.11
environment:
MYSQL_ROOT_PASSWORD: ${DB_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_NAME}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- db_data:/var/lib/mysql
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: 10s
timeout: 5s
retries: 5
restart: unless-stopped
redis:
image: redis:7-alpine
command: redis-server --requirepass ${REDIS_PASSWORD}
volumes:
- redis_data:/data
restart: unless-stopped
backend:
build: .
ports:
- "${BACKEND_PORT:-3000}:3000"
env_file: .env.prod
depends_on:
db:
condition: service_healthy
redis:
condition: service_started
restart: unless-stopped
frontend:
build:
context: ../leverage-frontend-neo
dockerfile: Dockerfile
ports:
- "${FRONTEND_PORT:-3001}:80"
restart: unless-stopped
botzone:
build:
# Adjust this path to match your server layout
context: /Users/yuzhe/projects/botzone-neo
dockerfile: Dockerfile
ports:
- "${BOTZONE_PORT:-3002}:3002"
env_file: /Users/yuzhe/projects/botzone-neo/.env.prod
depends_on:
- redis
restart: unless-stopped
nginx:
image: nginx:alpine
ports:
- "80:80"
- "443:443"
volumes:
- ./deploy/nginx.conf:/etc/nginx/conf.d/default.conf:ro
- ./deploy/certs:/etc/nginx/certs:ro
depends_on:
- backend
- frontend
- botzone
restart: unless-stopped
volumes:
db_data:
redis_data: