11# src/server/docker-compose.yaml
2- # This docker-compose file is intended for a production-like deployment on a single VM.
3- # It orchestrates the main application server along with all its required backend services
4- # (Redis, WAHA for WhatsApp, PostgreSQL for Memory, and ChromaDB for vector storage).
2+ # This docker-compose file is for deploying the application server on a dedicated Server VM.
3+ # It should connect to databases running on a separate Database VM.
54
65services :
76 # 1. The Main Sentient Application (FastAPI, Nginx, Celery, MCPs)
@@ -22,30 +21,12 @@ services:
2221 # This is the primary public-facing port for your entire application.
2322 - " 5000:80"
2423 depends_on :
25- - postgres
26- - chroma
27- - redis
2824 - waha
25+ - litellm
2926 networks :
3027 - sentient_network
3128
32- # 2. Redis for Celery Broker & Backend
33- redis :
34- image : redis:7-alpine
35- container_name : redis-db
36- restart : unless-stopped
37- # Use the password from the .env file, ensuring it's quoted
38- command : redis-server --requirepass "${REDIS_PASSWORD}"
39- volumes :
40- # Use a named volume for persistent Redis data
41- - redis-data:/data
42- networks :
43- - sentient_network
44- env_file :
45- - ./.env
46- # No ports are exposed to the host. Communication is internal and secure.
47-
48- # 3. WAHA (WhatsApp HTTP API) Service
29+ # 2. WAHA (WhatsApp HTTP API) Service
4930 waha :
5031 image : devlikeapro/waha:noweb
5132 container_name : waha-notifier
@@ -59,38 +40,8 @@ services:
5940 - ./.env
6041 ports :
6142 - " 8000:3000"
62- # No ports are exposed to the host. The sentient-app communicates with it internally.
63-
64- # 4. PostgreSQL for Memory MCP
65- postgres :
66- image : pgvector/pgvector:pg16
67- container_name : sentient-postgres-prod
68- restart : unless-stopped
69- environment :
70- # These variables should be defined in your .env file
71- POSTGRES_USER : ${POSTGRES_USER}
72- POSTGRES_PASSWORD : ${POSTGRES_PASSWORD}
73- POSTGRES_DB : ${POSTGRES_DB}
74- volumes :
75- - postgres-data:/var/lib/postgresql/data
76- ports :
77- - " 5432:5432" # Maps your local port 5432 to the container's port 5432
78- networks :
79- - sentient_network
80-
81- # 5. ChromaDB for Vector Storage
82- chroma :
83- image : chromadb/chroma
84- container_name : sentient-chroma-prod
85- restart : unless-stopped
86- ports :
87- - " 8002:8000" # Expose Chroma's port for debugging if needed
88- volumes :
89- - chroma-data:/chroma/.chroma/index
90- networks :
91- - sentient_network
9243
93- # 6 . LiteLLM Proxy for Gemini Models
44+ # 3 . LiteLLM Proxy for Gemini Models
9445 litellm :
9546 image : ghcr.io/berriai/litellm:main-latest # Use the latest stable image
9647 container_name : litellm-proxy
@@ -102,9 +53,6 @@ services:
10253 command : ["--config", "/app/config.yaml", "--port", "4000"] # Run with config; optional: add "--detailed_debug"
10354 env_file :
10455 - ./.env # Loads GEMINI_API_KEY and others
105- # depends_on: [] # No dependencies needed, but add if required (e.g., for a DB)
106- # ports: # Optional: Expose if you need external access (e.g., for testing)
107- # - "4000:4000"
10856
10957# Defines the shared network for all services
11058networks :
@@ -113,7 +61,4 @@ networks:
11361
11462# Defines the named volumes for data persistence
11563volumes :
116- redis-data :
117- waha-sessions :
118- postgres-data :
119- chroma-data :
64+ waha-sessions:
0 commit comments