File size: 691 Bytes
940f330
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
FROM python:3.11-slim

# System dependencies
RUN apt-get update && apt-get install -y \

    build-essential \
    git \
    python3-dev \
    libboost-all-dev \
    cmake \
    && rm -rf /var/lib/apt/lists/*

# Install RDKit (official wheels)
RUN pip install --upgrade pip && pip install rdkit-pypi

# Set workdir
WORKDIR /app

# Copy code
COPY . .

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

# Set environment variables for HuggingFace Spaces
ENV PORT=7860
ENV LOG_LEVEL=info
ENV ALLOWED_ORIGINS="*"

# Expose port for Spaces
EXPOSE 7860

# Start FastAPI server (Spaces expects python main.py)
CMD ["python", "main.py"]