.PHONY: up down logs seed clean health test demo # Start all services up: docker-compose up -d @echo "Waiting for services to be healthy..." @sleep 10 @make health # Stop all services down: docker-compose down # View logs logs: docker-compose logs -f # Seed initial data seed: docker-compose exec mcp python /app/ops/scripts/seed.py # Clean everything (including volumes) clean: docker-compose down -v docker system prune -f @if [ -d "neo4j/data" ]; then rm -rf neo4j/data; fi @if [ -d "postgres/data" ]; then rm -rf postgres/data; fi @if [ -d "frontend/.next" ]; then rm -rf frontend/.next; fi @if [ -d "frontend/node_modules" ]; then rm -rf frontend/node_modules; fi # Health check all services health: @echo "Checking service health..." @docker-compose exec neo4j cypher-shell -u neo4j -p password "MATCH (n) RETURN count(n) LIMIT 1" > /dev/null 2>&1 && echo "✅ Neo4j: Healthy" || echo "❌ Neo4j: Unhealthy" @docker-compose exec postgres pg_isready -U postgres > /dev/null 2>&1 && echo "✅ PostgreSQL: Healthy" || echo "❌ PostgreSQL: Unhealthy" @curl -s http://localhost:8000/health > /dev/null && echo "✅ MCP Server: Healthy" || echo "❌ MCP Server: Unhealthy" @curl -s http://localhost:3000 > /dev/null && echo "✅ Frontend: Healthy" || echo "❌ Frontend: Unhealthy" @docker-compose ps agent | grep -q "Up" && echo "✅ Agent: Running" || echo "❌ Agent: Not running" # Run integration test test: health @echo "Running integration test..." @make seed @sleep 5 @echo "Check http://localhost:3000 and Neo4j Browser at http://localhost:7474" # Demo workflow demo: @echo "Starting demo workflow..." @make clean @make up @make seed @echo "" @echo "🎉 Demo Ready!" @echo "1. Open http://localhost:3000 in your browser" @echo "2. Ask a question like: 'Show me all customers who have placed orders'" @echo "3. Watch the agent process through the workflow" @echo "4. Check Neo4j Browser at http://localhost:7474 (neo4j/password)" @echo "" @echo "During 5-minute pauses, you can edit instructions in Neo4j Browser:" @echo "MATCH (i:Instruction {status: 'pending'}) SET i.parameters = '{\"question\": \"new question\"}'" # Build all services build: docker-compose build # Restart specific service restart-agent: docker-compose restart agent restart-mcp: docker-compose restart mcp restart-frontend: docker-compose restart frontend # Debug commands debug-agent: docker-compose logs agent debug-mcp: docker-compose logs mcp debug-frontend: docker-compose logs frontend # Quick status check status: docker-compose ps