Repository navigation
Docker Deployment
Lyndon Kaleb edited this page Apr 15, 2026
·
1 revision
Run MC Presence in a Docker container. This is the recommended method for always-on setups like Unraid, Synology, or any Docker host.
docker run -d \
--name mc-presence \
--restart unless-stopped \
-p 3100:3100 \
-v mc-presence-data:/app/data \
-v mc-presence-auth:/app/.minecraft \
-e MC_HOST=play.yourserver.com \
-e MC_PORT=25565 \
ghcr.io/redzephon/minecraft-present-bot:latestOpen http://your-docker-host:3100 in your browser.
Create a docker-compose.yml:
services:
mc-presence:
image: ghcr.io/redzephon/minecraft-present-bot:latest
container_name: mc-presence
restart: unless-stopped
ports:
- "3100:3100"
volumes:
- ./data:/app/data
- ./mc-auth:/app/.minecraft
environment:
- MC_HOST=play.yourserver.com
- MC_PORT=25565
- WEB_PORT=3100
- ANTHROPIC_API_KEY=sk-ant-your-key-here
# Optional:
# - BRIDGE_URL=http://your-mc-server:3101
# - BRIDGE_SECRET=changeme
# - DISCORD_WEBHOOK=https://discord.com/api/webhooks/...
# - OWNER_USERNAME=YourMCNameThen run:
docker compose up -dIf you prefer to build the image yourself:
git clone https://github.com/RedZephon/Minecraft-Present-Bot.git
cd Minecraft-Present-Bot
docker build -t mc-presence .
docker run -d --name mc-presence \
--restart unless-stopped \
-p 3100:3100 \
-v ./data:/app/data \
-v ./mc-auth:/app/.minecraft \
-e MC_HOST=play.yourserver.com \
mc-presence| Volume | Purpose |
|---|---|
/app/data |
Bot configs (bots.json) and settings (settings.json). Mount this to persist across container restarts.
|
/app/.minecraft |
Microsoft auth tokens. Mount this so you don't have to re-authenticate every time the container restarts. |
All configuration is done via environment variables. See Configuration for the full list.
The most important ones:
| Variable | Required | Description |
|---|---|---|
MC_HOST |
Yes | Your Minecraft server address |
MC_PORT |
No | Server port (default: 25565) |
WEB_PORT |
No | Dashboard port (default: 3100) |
ANTHROPIC_API_KEY |
For AI | Anthropic API key for AI chat modes |
- Go to Docker > Add Container
- Set the Repository to the image URL
- Add port mapping: Container
3100→ Host3100 - Add path mappings:
-
/app/data→/mnt/user/appdata/mc-presence/data -
/app/.minecraft→/mnt/user/appdata/mc-presence/mc-auth
-
- Add environment variables for
MC_HOSTand any others you need - Click Apply
- Download the image from the registry
- Create a container with:
- Port: local
3100→ container3100 - Volumes: map a local folder to
/app/dataand/app/.minecraft - Environment: set
MC_HOST,MC_PORT, etc.
- Port: local
- Start the container
# Docker run
docker pull ghcr.io/redzephon/minecraft-present-bot:latest
docker stop mc-presence && docker rm mc-presence
# Re-run your docker run command
# Docker Compose
docker compose pull
docker compose up -dYour data and auth tokens persist in the mounted volumes.
docker logs mc-presence
docker logs -f mc-presence # follow liveCheck logs with docker logs mc-presence. Common causes:
- Missing required environment variables
- Port conflict (change
WEB_PORT)
- Verify the port mapping:
docker port mc-presence - Check your firewall allows traffic on port 3100
Make sure you're mounting /app/.minecraft as a volume. Without this, tokens are lost when the container restarts.