meshai/work/docker-compose.yml
malice 5de683f7a7
chore: remove legacy TUI configurator; surface last config gap in GUI (#45)
Audit confirmed the Rich TUI (`meshai --config`) is a strict subset of the
dashboard GUI (covers FEWER sections) and nothing depends on it for bootstrap.
Strip it so the dashboard is the single config surface.

- delete meshai/cli/configurator.py (~1435 lines); cli/__init__ minimal
- main.py: drop --config + run_configurator dispatch (keep --config-file);
  bootstrap log now points to config.example.yaml / the dashboard
- docker-entrypoint.sh: remove the ttyd `meshai --config` block on :7682
  (default-config heredoc + bot exec loop untouched)
- docker-compose.yml + Dockerfile: drop the 7682 port + ttyd install (EXPOSE 8080)
- README / config.py header / config.example.yaml: de-reference the TUI
- drop `rich` from pyproject + requirements (grep-verified unused)

Close the only GUI config gap the audit found:
- Config.tsx weather tab: add openmeteo.url + wttr.url inputs (backend already
  round-trips the nested WeatherConfig dataclasses)

Bootstrap intact: config.example.yaml copy, entrypoint default-config write,
and defaulted Config() when no file exists all remain. `python3 -m meshai`
and `--config-file` unchanged. TS/import validated at Docker build.

Co-authored-by: Matt Johnson <mj@k7zvx.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-05 16:21:32 -06:00

87 lines
2.1 KiB
YAML

# MeshAI Docker Compose Configuration
#
# Usage:
# docker compose up -d # Start the bot + dashboard
# docker compose logs -f # View logs
#
# Dashboard: http://localhost:8080
#
# Config is stored in the meshai_data volume at /data/config.yaml
#
# For serial connection (USB), uncomment the devices section below
# For TCP connection, edit config.yaml or use the dashboard
services:
meshai:
# Pull from GitHub Container Registry
# image: ghcr.io/zvx-echo6/meshai:latest
# Uncomment to build locally instead of pulling
build:
context: .
dockerfile: Dockerfile
# args:
# UID: ${UID:-1000}
# GID: ${GID:-1000}
container_name: meshai
restart: unless-stopped
# Resolve external HTTP feeds via the LXC host's working resolver
# (Tailscale MagicDNS, 100.100.100.100). The Docker daemon default
# of 1.1.1.1/8.8.8.8 is unreachable from this container's NAT egress,
# which silently broke NWS/SWPC/meshview hostname resolution.
dns:
- 100.100.100.100
- 1.1.1.1
# Uncomment for USB serial connection to Meshtastic device
# devices:
# - /dev/ttyUSB0:/dev/ttyUSB0
# - /dev/ttyACM0:/dev/ttyACM0
ports:
# Dashboard API
- "8080:8080"
volumes:
# Persistent data (database, config)
- meshai_data:/data
# Allocate a TTY for cleaner log output
stdin_open: true
tty: true
environment:
# API key can be set here or in config.yaml
- LLM_API_KEY=${LLM_API_KEY:-}
# Limit resources
deploy:
resources:
limits:
memory: 3G
reservations:
memory: 64M
healthcheck:
test: ["CMD-SHELL", "test -f /tmp/meshai.pid && kill -0 $(cat /tmp/meshai.pid) 2>/dev/null && [ \"$(cat /tmp/meshai.link 2>/dev/null)\" = up ] || exit 1"]
interval: 30s
timeout: 10s
retries: 3
start_period: 15s
logging:
driver: "json-file"
options:
max-size: "10m"
max-file: "3"
volumes:
meshai_data:
name: meshai_data
networks:
default:
name: meshai_network