-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.yml
80 lines (78 loc) · 1.84 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
name: "kzoj"
volumes:
app:
driver: "local"
mysql:
driver: "local"
minio:
driver: "local"
services:
app:
build:
context: "."
env_file:
- path: "./.env.default"
required: true
- path: "./.env.docker"
required: true
- path: "./.env"
required: false
environment:
- "KZOJ_SESSION_STORAGE_PATH=/app/data/.sessions"
volumes:
- "app:/app/data"
ports:
- "0.0.0.0:${KZOJ_APP_PORT:-8080}:8080"
depends_on:
mysql:
condition: "service_healthy"
minio:
condition: "service_healthy"
web:
build:
context: "https://git.nju.edu.cn/doowzs/kzoj.react.git#release"
ports:
- "0.0.0.0:${KZOJ_WEB_PORT:-3000}:3000"
sandbox:
build:
context: "."
dockerfile: "Dockerfile.sandbox"
privileged: true
shm_size: "256m"
ports:
- "127.0.0.1:${GO_JUDGE_PORT:-5050}:5050"
mysql:
image: "bitnami/mysql:9.0"
restart: "unless-stopped"
env_file:
- path: "./.env.default"
required: true
- path: "./.env"
required: false
volumes:
- "mysql:/bitnami/mysql/data"
ports:
- "127.0.0.1:${MYSQL_PORT:-3306}:3306"
healthcheck:
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
interval: "1m"
timeout: "10s"
start_period: "30s"
minio:
image: "bitnami/minio:2024.10.29"
restart: "unless-stopped"
volumes:
- "minio:/bitnami/minio/data"
env_file:
- path: "./.env.default"
required: true
- path: "./.env"
required: false
ports:
- "127.0.0.1:${MINIO_API_PORT:-9000}:9000"
- "127.0.0.1:${MINIO_CONSOLE_PORT:-9001}:9001"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: "1m"
timeout: "10s"
start_period: "30s"