99Isuru/Reef_Fish_Identifier
0
1FROM python:3.10-slim
2
3# Prevent Python from writing pyc files
4ENV PYTHONDONTWRITEBYTECODE=1
5ENV PYTHONUNBUFFERED=1
6
7WORKDIR /app
8
9# Install system dependencies (Pillow needs these)
10RUN apt-get update && apt-get install -y \
11 build-essential \
12 libgl1 \
13 libglib2.0-0 \
14 && rm -rf /var/lib/apt/lists/*
15
16# Install Python dependencies
17COPY requirements.txt .
18RUN pip install --no-cache-dir -r requirements.txt
19
20# Copy project files
21COPY . .
22
23# Hugging Face Spaces uses port 7860
24EXPOSE 7860
25
26# Run Flask app with Gunicorn
27CMD ["gunicorn", "-b", "0.0.0.0:7860", "app:app"]
28 