-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDocker-compose.yml
More file actions
66 lines (56 loc) · 1.28 KB
/
Docker-compose.yml
File metadata and controls
66 lines (56 loc) · 1.28 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
version: '3.8'
services:
flux-dashboard:
build:
context: .
dockerfile: Dockerfile
container_name: flux-dashboard
restart: unless-stopped
# Port configuration
ports:
- "3000:3000" # API port
- "5173:5173" # Frontend port
# Environment variables
environment:
- NODE_ENV=production
- HOST=0.0.0.0
- API_PORT=3000
- PORT=5173
- ORIGIN=http://localhost:5173
# Or use env file
# env_file:
# - .env.production
# Volume mounts for data persistence
volumes:
- ./data:/app/data
- ./logs:/app/logs
# Resource limits
deploy:
resources:
limits:
cpus: '2.0'
memory: 2G
reservations:
cpus: '0.5'
memory: 512M
# Health check
healthcheck:
test: ["CMD", "wget", "--no-verbose", "--tries=1", "--spider", "http://localhost:3000/api/health"]
interval: 30s
timeout: 10s
retries: 3
start_period: 15s
# Logging configuration
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
# Optional: Named volumes
volumes:
flux-data:
driver: local
# Optional: Custom network
networks:
flux-network:
driver: bridge