orchestrated-discussions/docker-compose.yml

136 lines
4.1 KiB
YAML

# Orchestrated Discussions - Multi-agent AI discussion orchestration
#
# Quick Start:
# docker-compose build # Build the image (clones SmartTools from Gitea)
# docker-compose run --rm test # Run tests
# docker-compose run --rm cli discussions --help
#
# Dependencies:
# - SmartTools (cloned automatically from Gitea during build)
version: '3.8'
services:
# ============================================================================
# Main CLI
# ============================================================================
cli:
build:
context: .
dockerfile: Dockerfile
args:
SMARTTOOLS_REPO: https://gitea.brrd.tech/rob/SmartTools.git
image: orchestrated-discussions:latest
volumes:
- smarttools-data:/root/.smarttools
- ./examples:/app/examples:ro
- ./templates:/app/templates:ro
command: ["discussions", "--help"]
# ============================================================================
# Tests
# ============================================================================
test:
build:
context: .
dockerfile: Dockerfile
args:
SMARTTOOLS_REPO: https://gitea.brrd.tech/rob/SmartTools.git
image: orchestrated-discussions:latest
volumes:
- smarttools-data:/root/.smarttools
- ./examples:/app/examples:ro
command: >
bash -c "
set -e
echo '=== Orchestrated Discussions Tests ==='
echo ''
echo '1. Checking SmartTools...'
smarttools list | head -5
echo ''
echo '2. Checking discussion tools...'
discussion-parser --help > /dev/null && echo 'discussion-parser: OK'
discussion-vote-counter --help > /dev/null && echo 'discussion-vote-counter: OK'
echo ''
echo '3. Checking discussions CLI...'
discussions --help > /dev/null && echo 'discussions CLI: OK'
discussions participants
echo ''
echo '4. Running unit tests...'
pytest -v tests/
echo ''
echo '5. Testing pipeline...'
cat examples/brainstorm_notification_system.discussion.md | discussion-parser | jq -r '.title'
echo 'Pipeline: OK'
echo ''
echo '=== All tests passed ==='
"
# ============================================================================
# GUI (requires X11 forwarding)
# ============================================================================
gui:
build:
context: .
dockerfile: Dockerfile
args:
SMARTTOOLS_REPO: https://gitea.brrd.tech/rob/SmartTools.git
image: orchestrated-discussions:latest
environment:
- DISPLAY=${DISPLAY:-:0}
volumes:
- smarttools-data:/root/.smarttools
- ./examples:/app/examples
- /tmp/.X11-unix:/tmp/.X11-unix:ro
command: ["discussions", "ui"]
network_mode: host
# ============================================================================
# Interactive Shell
# ============================================================================
shell:
build:
context: .
dockerfile: Dockerfile
args:
SMARTTOOLS_REPO: https://gitea.brrd.tech/rob/SmartTools.git
image: orchestrated-discussions:latest
volumes:
- smarttools-data:/root/.smarttools
- ./examples:/app/examples
- ./templates:/app/templates
command: ["/bin/bash"]
stdin_open: true
tty: true
volumes:
smarttools-data:
# Persists ~/.smarttools between container runs
# ==============================================================================
# Usage Examples
# ==============================================================================
#
# Build (fetches SmartTools from Gitea automatically):
# docker-compose build
#
# Run tests:
# docker-compose run --rm test
#
# Use CLI:
# docker-compose run --rm cli discussions participants
# docker-compose run --rm cli discussions status examples/feature_discussion.discussion.md
# docker-compose run --rm cli discussions new "My Feature" --template feature
#
# Launch GUI (requires: xhost +local:docker):
# docker-compose run --rm gui
#
# Interactive shell:
# docker-compose run --rm shell