CoolFace
Apppublic

yasserrmd/CareerCompass

sourceHugging Faceupdated 2y agoView on Hugging Face
0likes
Dockerfile28 linesDownload Raw Back to root
1# Use Python 3.11 as the base image2FROM python:3.113 4# Create a non-root user5RUN useradd -m -u 1000 user6 7# Switch to the non-root user8USER user9 10# Set the environment PATH to include user's local bin11ENV PATH="/home/user/.local/bin:$PATH"12 13# Set the working directory14WORKDIR /app15 16# Copy the requirements file and install dependencies17COPY --chown=user ./requirements.txt requirements.txt18RUN pip install --no-cache-dir --upgrade -r requirements.txt19 20# Copy the application files to the working directory21COPY --chown=user . /app22 23# Expose the port that the application will run on24EXPOSE 786025 26# Start the FastAPI application using uvicorn27CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]28