CoolFace
Apppublic

palondomus/CaesarAIShowCase

sourceHugging Faceupdated 3y agoView on Hugging Face
0likes
Dockerfile47 linesDownload Raw Back to root
1FROM tensorflow/tensorflow:latest-gpu-jupyter2 3#VOLUME CaesarAINL CaesarAINL4#WORKDIR /CaesarAINL 5 6#ADD CaesarAINL /CaesarAINL 7 8#RUN pip install flask flask_cors tensorflow_hub tensorflow_text scikit-learn tqdm matplotlib gunicorn9 10#EXPOSE 5000 11#8012 13#ENTRYPOINT [ "python" ]14#CMD ["app.py"]15 16# Use the official Python 3.9 image17FROM python:3.918RUN export PYTHONPATH=$PWD19RUN apt-get update && apt-get install curl ffmpeg libsm6 libxext6 uvicorn libopencv-dev python3-opencv libgirepository1.0-dev tesseract-ocr -y20RUN pip install uvicorn21# Set the working directory to /code22WORKDIR /code23#VOLUME /home/amari/Desktop/CaesarAI/CaesarFastAPI /code24# Copy the current directory contents into the container at /code25COPY ./requirements.txt /code/requirements.txt26 27# Install requirements.txt 28RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt29 30# Set up a new user named "user" with user ID 100031RUN useradd -m -u 1000 user32# Switch to the "user" user33USER user34# Set home to the user's home directory35ENV HOME=/home/user \36	PATH=/home/user/.local/bin:$PATH37 38# Set the working directory to the user's home directory39WORKDIR $HOME/app40 41# Copy the current directory contents into the container at $HOME/app setting the owner to the user42COPY --chown=user . $HOME/app43 44CMD ["uvicorn", "CaesarAIAPI/CaesarAI/main:app", "--host", "0.0.0.0", "--port", "7860","--reload"]45 46 47