File size: 762 Bytes
a99d4dc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
85ff768
 
c4decf6
a99d4dc
 
 
 
88ad9bb
a99d4dc
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
FROM python:3.12-slim

WORKDIR /app

# Install dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# Copy application code
COPY dashboard.py .
COPY ai_search.py .
COPY algorithms.py .
COPY data_structures.py .
COPY indexer.py .
COPY search.py .
COPY semantic_search.py .
COPY hybrid_search.py .
COPY gemini_client.py .
COPY stylometry.py .
COPY schema.sql .
COPY static/ static/
COPY templates/ templates/

# DB is downloaded from HF Dataset repo on startup (see ensure_db_exists in dashboard.py)

# HF Spaces uses port 7860
ENV PORT=7860
ENV HOST=0.0.0.0
ENV DB_PATH=telegram.db

EXPOSE 7860

CMD ["gunicorn", "dashboard:app", "--bind", "0.0.0.0:7860", "--workers", "2", "--timeout", "120"]