Documentation
Reference
Ports, install paths, units, and environment variables for a production panel.
Ports
| Port | Process | Bind |
|---|---|---|
| 3010 | flutter-web (Next.js) | 127.0.0.1 in production; public if --no-nginx |
| 4000 | flutter-api (Hono) | 127.0.0.1 in production |
| 8080 | flutter-daemon | 0.0.0.0 — panel must be able to reach this |
| 80 / 443 | nginx | public HTTP(S) → web + /api/ |
| 27017 | MongoDB | 127.0.0.1 |
| 6379 | Redis | 127.0.0.1 |
| 3040 | These docs (Next.js) | this site only |
Paths
| Path | Role |
|---|---|
| /opt/flutter | Panel install (user flutter) |
| /opt/flutter/.env | Secrets and URLs (mode 640) |
| /opt/flutter/apps/daemon/data/config.json | Local daemon config on a combined host |
| /opt/flutter-node | Daemon-only install |
| /var/lib/flutter | Game server files |
| /usr/local/src/flutter-panel | Git checkout used by the installer |
| /usr/local/sbin/flutter-update | Production updater |
| /usr/local/sbin/flutter-restart | Restart panel units |
systemd units
| Unit | Role |
|---|---|
| flutter-api | API |
| flutter-web | Dashboard |
| flutter-daemon | Game node agent |
| flutter-node-tunnel | Cloudflare quick tunnel (home node only) |
Environment
Written by the installer or npm run setup. Do not commit this file.
| Variable | Meaning |
|---|---|
| APP_URL | Public panel URL (cookie + links) |
| API_INTERNAL_URL | How the web process reaches the API (default http://127.0.0.1:4000) |
| DATABASE_URL | MongoDB connection string (replica set in Compose) |
| REDIS_URL | Redis connection string |
| SESSION_SECRET | Cookie signing (≥ 32 chars) |
| DAEMON_REQUEST_SECRET | Panel → daemon request auth |
| COOKIE_SECURE | true when APP_URL is https |
| SMTP_HOST / PORT / USER / PASS / FROM | Optional mailer fallback |
| PORT / HOST | API listen (default 4000 / 0.0.0.0) |
Health
bash
curl -sS https://panel.example.com/api/v1/health
curl -sS http://NODE_IP:8080/healthAPI health requires Mongo + Prisma. Redis is reported. Daemon /health is what the panel uses when it cannot start or stream console.