-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
49 lines (44 loc) · 1.38 KB
/
Copy pathdocker-compose.yml
File metadata and controls
49 lines (44 loc) · 1.38 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
version: '3.8'
services:
ai-minecraft-bot:
build: .
container_name: ai-minecraft-bot
restart: unless-stopped
# Use host networking for direct access to localhost
network_mode: host
environment:
- GEMINI_API_KEY=${GEMINI_API_KEY}
- SERVER_IP=localhost # Can use localhost with host networking
- PORT=19132
- BOT_NAME=AI_Admin
- DEBUG_MODE=true
volumes:
# Mount logs directory for persistence
- ./logs:/usr/src/app/logs
# Mount structures directory for persistence
- ./structures:/usr/src/app/structures
# Health check to ensure bot is running
healthcheck:
test: ["CMD", "node", "-e", "process.exit(0)"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
# Note: With host networking, the container uses the host's network stack directly
# This allows direct access to localhost services like your Minecraft server
# Optional: Add a simple web dashboard (future enhancement)
# services:
# dashboard:
# image: nginx:alpine
# ports:
# - "8080:80"
# Note: When using host networking, custom networks are not needed
# The container will use the host's network stack directly
# Optional: Add a simple web dashboard (future enhancement)
# services:
# dashboard:
# image: nginx:alpine
# ports:
# - "8080:80"
# networks:
# - minecraft-network