sarim/SwiftUI_object_deteaction
0
1# Use the official Python 3.9 image2FROM python:3.93 4 5# Set the working directory to /code6WORKDIR /code7 8# Copy the current directory contents into the container at /code9COPY ./requirements.txt /code/requirements.txt10 11# Install requirements.txt 12RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt13 14# Set up a new user named "user" with user ID 100015RUN useradd -m -u 1000 user16# Switch to the "user" user17USER user18# Set home to the user's home directory19ENV HOME=/home/user \20 PATH=/home/user/.local/bin:$PATH21 22# Set the working directory to the user's home directory23WORKDIR $HOME/app24 25# Copy the current directory contents into the container at $HOME/app setting the owner to the user26COPY --chown=user . $HOME/app27 28CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]