Hemodialysis-Bot / Dockerfile
fikriazain's picture
fix adjustment
cfa4af6
raw
history blame contribute delete
529 Bytes
# Use Python 3.11 as the base image
FROM python:3.11
# Create a non-root user
RUN useradd -m -u 1000 user
USER user
# Set the environment path for pip packages
ENV PATH="/home/user/.local/bin:$PATH"
# Set working directory
WORKDIR /server
# Copy and install dependencies
COPY --chown=user requirements.txt requirements.txt
RUN pip install --no-cache-dir --upgrade -r requirements.txt
# Copy all files to the container
COPY --chown=user . /server
# Expose Flask port
EXPOSE 7860
# Run Flask app
CMD ["python", "server.py"]