feat: Added Docker Support and missing dependencies.

This commit is contained in:
DESKTOP-RTLN3BA\$punk 2025-03-20 18:52:06 -07:00
parent c5287829b6
commit 709aa6f303
9 changed files with 1004 additions and 24 deletions

48
docker-compose.yml Normal file
View file

@ -0,0 +1,48 @@
version: '3.8'
services:
frontend:
build:
context: ./surfsense_frontend
dockerfile: Dockerfile
ports:
- "3000:3000"
volumes:
- ./surfsense_frontend:/app
- /app/node_modules
depends_on:
- backend
environment:
- NEXT_PUBLIC_API_URL=http://backend:8000
backend:
build:
context: ./surfsense_backend
dockerfile: Dockerfile
ports:
- "8000:8000"
volumes:
- ./surfsense_backend:/app
depends_on:
- db
env_file:
- ./surfsense_backend/.env
environment:
- DATABASE_URL=postgresql+asyncpg://postgres:postgres@db:5432/surfsense
- PYTHONPATH=/app
- UVICORN_LOOP=asyncio
- UNSTRUCTURED_HAS_PATCHED_LOOP=1
db:
image: ankane/pgvector:latest
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
environment:
- POSTGRES_USER=postgres
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=surfsense
volumes:
postgres_data: