File size: 734 Bytes
03a6894
f0a4c0b
03a6894
f0a4c0b
03a6894
 
 
 
 
f0a4c0b
03a6894
 
 
f0a4c0b
03a6894
 
 
f0a4c0b
03a6894
 
f0a4c0b
03a6894
 
f0a4c0b
03a6894
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM python:3.11-slim

WORKDIR /app

ENV PYTHONUNBUFFERED=1 \
    PORT=7860 \
    STREAMLIT_SERVER_HEADLESS=true \
    STREAMLIT_BROWSER_GATHERUSAGESTATS=false \
    STREAMLIT_CONFIG_DIR=/app/.streamlit

# minimal OS deps + tini for clean PID 1
RUN apt-get update && apt-get install -y --no-install-recommends \
    ca-certificates curl tini && rm -rf /var/lib/apt/lists/*

# Python deps
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt

# App code
COPY . .

# avoid permission errors for Streamlit internal files
RUN mkdir -p /app/.streamlit && chmod -R 777 /app/.streamlit

EXPOSE 7860
ENTRYPOINT ["/usr/bin/tini", "--"]
CMD ["streamlit", "run", "app.py", "--server.address=0.0.0.0", "--server.port=7860"]