oculus / Dockerfile
jaanya
HuggingFace deployment config
7172ad4
Raw History Blame Contribute Delete
720 Bytes
FROM python:3.11-slim
WORKDIR /app
# Install system dependencies
RUN apt-get update && apt-get install -y \
curl \
gcc \
g++ \
&& rm -rf /var/lib/apt/lists/*
# Copy and install Python dependencies
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
# Copy all project files
COPY . .
# Create necessary directories
RUN mkdir -p data chroma_db static
# Download MITRE ATT&CK data at build time so cold starts are fast
RUN curl -L "https://raw.githubusercontent.com/mitre/cti/master/enterprise-attack/enterprise-attack.json" \
-o data/mitre_attack.json
# HuggingFace Spaces requires port 7860
EXPOSE 7860
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]