Add ChromaDB implementation

This commit is contained in:
2025-12-10 12:46:17 +00:00
parent 57f37c8dc0
commit 6c8d6d0940
7 changed files with 384 additions and 7 deletions

View File

@@ -38,7 +38,7 @@ services:
# count: all
# capabilities: [gpu]
healthcheck:
test: ["CMD-SHELL", "ollama list || exit 1"]
test: [ "CMD-SHELL", "ollama list || exit 1" ]
interval: 30s
timeout: 10s
retries: 3
@@ -72,7 +72,7 @@ services:
networks:
- munich-news-network
healthcheck:
test: ["CMD", "redis-cli", "ping"]
test: [ "CMD", "redis-cli", "ping" ]
interval: 30s
timeout: 10s
retries: 3
@@ -100,6 +100,24 @@ services:
timeout: 10s
retries: 3
# ChromaDB - Vector Database for AI features
chromadb:
image: chromadb/chroma:latest
container_name: munich-news-chromadb
restart: unless-stopped
# No ports exposed - only accessible within Docker network
environment:
- IS_PERSISTENT=TRUE
volumes:
- chromadb_data:/chroma/chroma
networks:
- munich-news-network
healthcheck:
test: [ "CMD", "curl", "-f", "http://localhost:8000/api/v1/heartbeat" ]
interval: 30s
timeout: 10s
retries: 3
# News Crawler - Runs at 6 AM Berlin time
crawler:
build:
@@ -120,7 +138,7 @@ services:
networks:
- munich-news-network
healthcheck:
test: ["CMD", "python", "-c", "import sys; sys.exit(0)"]
test: [ "CMD", "python", "-c", "import sys; sys.exit(0)" ]
interval: 1m
timeout: 10s
retries: 3
@@ -149,7 +167,7 @@ services:
- munich-news-network
- proxy
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5001/health')"]
test: [ "CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5001/health')" ]
interval: 30s
timeout: 10s
retries: 3
@@ -188,7 +206,7 @@ services:
networks:
- munich-news-network
healthcheck:
test: ["CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5002/health')"]
test: [ "CMD", "python", "-c", "import urllib.request; urllib.request.urlopen('http://localhost:5002/health')" ]
interval: 30s
timeout: 10s
retries: 3
@@ -214,7 +232,7 @@ services:
networks:
- munich-news-network
healthcheck:
test: ["CMD", "python", "-c", "import sys; sys.exit(0)"]
test: [ "CMD", "python", "-c", "import sys; sys.exit(0)" ]
interval: 1m
timeout: 10s
retries: 3
@@ -239,7 +257,7 @@ services:
- munich-news-network
- proxy
healthcheck:
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:3000"]
test: [ "CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:3000" ]
interval: 30s
timeout: 10s
retries: 3
@@ -264,6 +282,8 @@ volumes:
driver: local
ollama_data:
driver: local
chromadb_data:
driver: local
networks:
munich-news-network: