|
|
FROM python:3.9-slim |
|
|
|
|
|
|
|
|
WORKDIR /app |
|
|
|
|
|
|
|
|
RUN apt-get update && apt-get install -y \ |
|
|
build-essential \ |
|
|
curl \ |
|
|
software-properties-common \ |
|
|
git \ |
|
|
libgl1-mesa-glx \ |
|
|
libglib2.0-0 \ |
|
|
&& rm -rf /var/lib/apt/lists/* |
|
|
|
|
|
|
|
|
COPY requirements.txt . |
|
|
RUN pip install --no-cache-dir -r requirements.txt |
|
|
|
|
|
|
|
|
COPY app/ ./app/ |
|
|
COPY README.md . |
|
|
COPY .streamlit/ ./.streamlit/ |
|
|
|
|
|
|
|
|
RUN mkdir -p data logs |
|
|
|
|
|
|
|
|
EXPOSE 8501 |
|
|
|
|
|
|
|
|
HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health || exit 1 |
|
|
|
|
|
|
|
|
ENV STREAMLIT_SERVER_PORT=8501 |
|
|
ENV STREAMLIT_SERVER_ADDRESS=0.0.0.0 |
|
|
|
|
|
|
|
|
ENTRYPOINT ["streamlit", "run", "app/main.py", "--server.port=8501", "--server.address=0.0.0.0"] |
|
|
|