mcdosbox-x/docker-compose.yml
Ryan Malloy 170eba0843 Initial implementation of DOSBox-X MCP Server
MCP server for AI-assisted debugging of DOS binaries via GDB protocol.

Features:
- GDB remote protocol client for DOSBox-X debugging
- 16 debugging tools: launch, attach, breakpoint management,
  registers, memory read/write, disassemble, step, continue, etc.
- Docker container with DOSBox-X for consistent environment
- Support for DOS segment:offset addressing
- Comprehensive test suite (49 tests)

Primary use case: Reverse engineering the unpublished Bezier algorithm
in RIPTERM.EXE for the RIPscrip graphics protocol project.
2026-01-27 13:07:51 -07:00

96 lines
2.2 KiB
YAML

# DOSBox-X MCP Docker Compose
#
# Usage:
# docker compose up -d # Start DOSBox-X
# docker compose logs -f # View logs
# docker compose down # Stop
#
# For GUI (X11 forwarding):
# xhost +local:docker # Allow Docker X11 access
# docker compose up -d
services:
dosbox:
build:
context: .
dockerfile: Dockerfile
container_name: dosbox-mcp
# Ports
ports:
- "${GDB_PORT:-1234}:1234" # GDB stub
- "${SERIAL_PORT:-5555}:5555" # Serial (optional)
# X11 forwarding for display
environment:
- DISPLAY=${DISPLAY:-:0}
volumes:
- /tmp/.X11-unix:/tmp/.X11-unix:rw
- ${XDG_RUNTIME_DIR:-/run/user/1000}:${XDG_RUNTIME_DIR:-/run/user/1000}:rw
# DOS files directory
- ${DOS_DIR:-./dos}:/dos:rw
# Custom config (optional)
- ${CONFIG_FILE:-./config/dosbox.conf}:/config/dosbox.conf:ro
# Audio (PulseAudio)
devices:
- /dev/snd:/dev/snd
# For PulseAudio sound
# Uncomment if you want sound support:
# - ${XDG_RUNTIME_DIR}/pulse:/run/user/1000/pulse:rw
# Run options
stdin_open: true
tty: true
# Resource limits
deploy:
resources:
limits:
cpus: '2'
memory: 1G
# Healthcheck - verify GDB port is listening
healthcheck:
test: ["CMD-SHELL", "nc -z localhost 1234 || exit 1"]
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
# Restart policy
restart: unless-stopped
# Optional: Separate container for headless operation
dosbox-headless:
build:
context: .
dockerfile: Dockerfile
container_name: dosbox-mcp-headless
profiles:
- headless
ports:
- "${GDB_PORT_HEADLESS:-1235}:1234"
environment:
# Use virtual framebuffer for headless
- SDL_VIDEODRIVER=dummy
- SDL_AUDIODRIVER=dummy
volumes:
- ${DOS_DIR:-./dos}:/dos:rw
- ${CONFIG_FILE:-./config/dosbox.conf}:/config/dosbox.conf:ro
stdin_open: true
tty: true
deploy:
resources:
limits:
cpus: '1'
memory: 512M