Dockerfile 580 B

12345678910111213141516171819202122
  1. #ident "@(#)$Format:LocalFoodAI:app.py:%an:%ae:%ad:%cn:%ce:%cd:%H:%D:%N$"
  2. # Dockerfile for Streamlit UI
  3. FROM python:3.11-slim
  4. # Install system dependencies
  5. RUN apt-get update && apt-get install -y --no-install-recommends \
  6. build-essential \
  7. default-libmysqlclient-dev \
  8. snmp \
  9. && rm -rf /var/lib/apt/lists/*
  10. WORKDIR /app
  11. COPY requirements.txt ./
  12. RUN pip install --no-cache-dir -r requirements.txt
  13. # Copy application code and version files
  14. COPY *.py *.txt ./
  15. EXPOSE 8501
  16. CMD ["streamlit", "run", "app.py", "--server.port", "8501", "--server.headless", "true"]