CoolFace
Apppublic

abadesalex/DocuRAG

sourceHugging Faceapache-2.0updated 2y agoView on Hugging Face
0likes
Dockerfile34 linesDownload Raw Back to root
1FROM python:3.92 3# Set up a new user named "user" with user ID 10004RUN useradd -m -u 1000 user5 6# Switch to the "user" user7USER user8 9# Set home to the user's home directory and Gensim data directory10ENV HOME=/home/user \11    GENSIM_DATA_DIR=/home/user/gensim-data \12    PATH=/home/user/.local/bin:$PATH13 14# Set the working directory to the user's home directory15WORKDIR $HOME/app16 17# Upgrade pip and install dependencies18COPY --chown=user ./Api/requirements.txt /home/user/app/requirements.txt19RUN pip install --no-cache-dir --upgrade pip \20    && pip install --no-cache-dir --upgrade -r /home/user/app/requirements.txt21 22# Install additional packages23USER root24RUN apt update && apt install -y ffmpeg25USER user26 27# Copy the application code and set the owner to the user28COPY --chown=user ./Api/app /home/user/app/app29 30# Expose the port the app runs on31EXPOSE 800032 33# Command to run the application34CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8000"]