dep_teat / Dockerfile
karthikrathod's picture
Update Dockerfile
ee19447 verified
raw
history blame
574 Bytes
# Base image
FROM python:3.9
# Set a non-root user
RUN useradd -m appuser
USER appuser
# Set working directory
WORKDIR /code
# Copy requirements file and install dependencies
COPY --chown=appuser ./requirements.txt /code/requirements.txt
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
# Create storage directory with proper permissions
RUN mkdir -p /storage
RUN chown appuser:appuser /storage
# Copy application code
COPY --chown=appuser . /code
# Set the command to run the app
CMD ["streamlit", "run", "streamlit_app.py", "--server.port", "7860"]