Skin_Cancer_Dashboard / Dockerfile
MoritzMMuller's picture
Update Dockerfile
dd80f04 verified
raw
history blame
789 Bytes
# Use official slim Python base image
FROM python:3.10-slim
# Prevent Python from writing .pyc files
ENV PYTHONDONTWRITEBYTECODE=1
# Buffer stdout/stderr for easier logging
ENV PYTHONUNBUFFERED=1
# Install OS dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential \
libgl1-mesa-glx \
libglib2.0-0 \
&& rm -rf /var/lib/apt/lists/*
# Set working directory
WORKDIR /app
# Copy and install Python dependencies
COPY requirements.txt ./
RUN pip install --upgrade pip \
&& pip install --no-cache-dir -r requirements.txt
# Copy application code
COPY . /app
# Expose Streamlit default port
EXPOSE 8501
# Run the Streamlit app on container start
CMD ["streamlit", "run", "app.py", "--server.port=8501", "--server.address=0.0.0.0"]