-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
48 lines (45 loc) · 1.05 KB
/
Copy pathdocker-compose.yml
File metadata and controls
48 lines (45 loc) · 1.05 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
version: '3.9'
services:
app:
build: .
container_name: goadminx
ports:
- "8080:8080"
environment:
- GIN_MODE=release
volumes:
- ./server/config.yaml:/app/config.yaml
- ./data/uploads:/app/uploads
- ./data/logs:/app/logs
- ./data/db:/app/data
depends_on:
redis:
condition: service_healthy
restart: unless-stopped
redis:
image: redis:7-alpine
container_name: goadminx-redis
ports:
- "6379:6379"
volumes:
- ./data/redis:/data
healthcheck:
test: ["CMD", "redis-cli", "ping"]
interval: 10s
timeout: 3s
retries: 3
restart: unless-stopped
# Optional: MySQL (uncomment if using MySQL instead of SQLite)
# mysql:
# image: mysql:8.0
# container_name: goadminx-mysql
# environment:
# MYSQL_ROOT_PASSWORD: root123
# MYSQL_DATABASE: goadminx
# MYSQL_USER: admin
# MYSQL_PASSWORD: admin123
# ports:
# - "3306:3306"
# volumes:
# - ./data/mysql:/var/lib/mysql
# restart: unless-stopped