Necoconeco is a distributed file synchronization system for markdown files, using RabbitMQ for real-time messaging and HTTP for file operations. The system consists of a file server and multiple clients that can sync files in real-time.
# Build server (requires 'server' build tag)
go build -tags server -o server server.go
# Build client (requires 'client' build tag)
go build -tags client -o client client.go
# Build sync client (requires 'clientsync' build tag)
go build -tags clientsync -o clientsync clientsync.go
# Run integration tests
go test ./integration_test/... -v
# Start with Docker Compose for development
docker-compose -f docker-compose.prod.yml up
# Or use manual startup scripts
./scripts/start.sh # Unix/Linux/macOS
./scripts/start.bat # Windows
server.go): Central file server that handles HTTP API requests and publishes events to RabbitMQProcesses client snapshots for synchronization
Client (client.go): Real-time file watcher that syncs local changes to server
Handles bidirectional file synchronization
Client Sync (clientsync.go): Initial synchronization client
internal/api/: HTTP API client and request/response typesinternal/utils/: File operations, metadata handling, and utility functionsintegration_test/: Comprehensive integration tests using testcontainersThe system uses a Last-Write-Wins (LWW) conflict resolution strategy with tombstones for deletions. File metadata includes timestamps and content hashes for conflict detection.
Required environment variables (usually in .env file):
CLIENT_ID: Unique identifier for each clientSYNC_DIRECTORY: Local directory to syncRABBITMQ_ADDRESS: RabbitMQ connection stringRABBITMQ_EXCHANGE_NAME: Exchange name for messagingRABBITMQ_ROUTING_KEY: Routing key for messagesRABBITMQ_QUEUE_NAME: Queue name for client (client only)SYNC_SERVER_URL: HTTP URL of the file serverPORT: Server port (server only)$ claude mcp add necoconeco \
-- python -m otcore.mcp_server <graph>