108 lines
2.1 KiB
YAML
108 lines
2.1 KiB
YAML
services:
|
|
|
|
mariadb:
|
|
image: mariadb:latest
|
|
restart: always
|
|
env_file:
|
|
- .env
|
|
ports:
|
|
- "${DB_PORT:-3306}:3306"
|
|
volumes:
|
|
- maria_data:/var/lib/mysql
|
|
networks:
|
|
- backend
|
|
|
|
phpmyadmin:
|
|
image: phpmyadmin/phpmyadmin
|
|
restart: always
|
|
ports:
|
|
- "${PHPMYADMIN_PORT:-8080}:80"
|
|
env_file:
|
|
- .env
|
|
networks:
|
|
- backend
|
|
depends_on:
|
|
- mariadb
|
|
|
|
qdrant:
|
|
image: qdrant/qdrant
|
|
restart: always
|
|
ports:
|
|
- "${QDRANT_PORT:-6333}:6333"
|
|
volumes:
|
|
- qdrant_data:/qdrant/storage
|
|
networks:
|
|
- backend
|
|
|
|
ollama:
|
|
image: ollama/ollama:latest
|
|
restart: always
|
|
ports:
|
|
- "${OLLAMA_PORT:-11434}:11434"
|
|
volumes:
|
|
- ollama_data:/root/.ollama
|
|
env_file:
|
|
- .env
|
|
environment:
|
|
- NVIDIA_DRIVER_CAPABILITIES=${OLLAMA_NVIDIA_CAPABILITIES}
|
|
- NVIDIA_VISIBLE_DEVICES=${OLLAMA_NVIDIA_VISIBLE_DEVICES}
|
|
networks:
|
|
- backend
|
|
deploy: # Specify runtime NVIDIA
|
|
resources:
|
|
reservations:
|
|
devices:
|
|
- driver: nvidia
|
|
capabilities: [ gpu ]
|
|
count: all
|
|
|
|
rag-service:
|
|
build: ./agent
|
|
# image: thestefano/crohngpt:latest
|
|
env_file:
|
|
- .env
|
|
ports:
|
|
- "${RAG_SERVICE_PORT:-8000}:8000"
|
|
volumes:
|
|
- pdfs:/app/pdfs
|
|
- ./agent/app:/app
|
|
depends_on:
|
|
- qdrant
|
|
- mariadb
|
|
- ollama
|
|
networks:
|
|
- backend
|
|
- frontend # Add frontend network to allow direct communication with React app
|
|
restart: always
|
|
deploy:
|
|
replicas: 1
|
|
|
|
real-time-chat-app:
|
|
build:
|
|
context: ./real-time-chat-app
|
|
dockerfile: Dockerfile
|
|
env_file:
|
|
- .env
|
|
environment:
|
|
- REACT_APP_API_BASE_URL=${REACT_APP_API_BASE_URL}
|
|
ports:
|
|
- "${REACT_APP_PORT:-3000}:3000" # React app
|
|
networks:
|
|
- frontend
|
|
restart: always
|
|
depends_on:
|
|
- rag-service
|
|
deploy:
|
|
replicas: 1
|
|
|
|
volumes:
|
|
qdrant_data:
|
|
pdfs:
|
|
maria_data:
|
|
ollama_data:
|
|
|
|
networks:
|
|
backend:
|
|
driver: bridge
|
|
frontend:
|
|
driver: bridge
|