Files
oh-my-pi/docker-compose.yml
T
can1357 88f5369d74 config: configured container mounts for AGENTS context and rule files
- Mounted the host's AGENTS.md context file into /root/.agent/AGENTS.md with read-only access.
- Mounted the host's .agent/rules directory into /root/.agent/rules for in-container rule discovery.
2026-05-15 00:19:34 +02:00

40 lines
1.6 KiB
YAML

services:
robomp:
build:
context: .
dockerfile: Dockerfile
additional_contexts:
# Built by `bin/stage-pi.sh` (rsynced pi checkout sans target/runs/...).
# The runtime mount below still points at the full $PI_ROOT.
pi: ./.pi-context
image: robomp:dev
container_name: robomp
restart: unless-stopped
env_file: .env
environment:
ROBOMP_OMP_COMMAND: omp
ROBOMP_WORKSPACE_ROOT: /data/workspaces
ROBOMP_SQLITE_PATH: /data/robomp.sqlite
ROBOMP_LOG_DIR: /data/logs
PI_ROOT: /work/pi
# Resolve `llm-gateway.internal` (used in ~/.omp/agent/models.yml) to the
# Docker host. The actual gateway listens on 127.0.0.1:4000 on the host;
# `host-gateway` is Docker's alias for the host bridge IP.
extra_hosts:
- "llm-gateway.internal:host-gateway"
volumes:
- ${PI_ROOT:-/work/pi}:/work/pi:ro
- ./data:/data
# Provider config (proxy endpoints + stub api keys). Credentials stay on
# the host; only the routing config is exposed to the container.
- ${HOME}/.omp/agent/models.yml:/root/.omp/agent/models.yml:ro
# Personal omp agent config from the host: the global AGENTS.md context
# file and the rules library. The loader (`packages/coding-agent/src/
# discovery/agents.ts`) walks `~/.agent/{AGENTS.md,rules,…}`, so we mount
# the host's `AGENT.md` (singular) onto the container path `AGENTS.md`
# (plural) to match the expected name without renaming on the host.
- ${HOME}/.agent/AGENT.md:/root/.agent/AGENTS.md:ro
- ${HOME}/.agent/rules:/root/.agent/rules:ro
ports:
- "8080:8080"