willemjan/glucose-dashboard/pipeline/head There was a failure building this commit
27 lines
654 B
Docker
27 lines
654 B
Docker
FROM python:3.12-slim
|
|
|
|
ENV HOME=/app \
|
|
PYTHONUNBUFFERED=1 \
|
|
STREAMLIT_SERVER_PORT=8501 \
|
|
STREAMLIT_SERVER_ADDRESS=0.0.0.0 \
|
|
STREAMLIT_SERVER_HEADLESS=true \
|
|
STREAMLIT_BROWSER_GATHER_USAGE_STATS=false
|
|
|
|
WORKDIR /app
|
|
|
|
# Systeem-dependency voor de HEALTHCHECK hieronder
|
|
RUN apt-get update && apt-get install -y --no-install-recommends curl \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
COPY requirements.txt .
|
|
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
COPY . .
|
|
|
|
RUN chgrp -R 0 /app && chmod -R g=u /app
|
|
|
|
USER 1001
|
|
EXPOSE 8501
|
|
HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health || exit 1
|
|
CMD ["streamlit", "run", "app.py"]
|