huanngzh commited on
Commit
4921b0c
·
1 Parent(s): 45fcca6
Files changed (1) hide show
  1. Dockerfile +8 -1
Dockerfile CHANGED
@@ -28,17 +28,22 @@ ENV LIBRARY_PATH=${CUDA_HOME}/lib64/stubs:${LIBRARY_PATH}
28
  RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
29
  build-essential \
30
  curl \
 
31
  git \
 
 
32
  libegl1-mesa-dev \
33
  libgl1-mesa-dev \
34
  libgles2-mesa-dev \
35
  libglib2.0-0 \
 
36
  libsm6 \
37
  libxext6 \
38
  libxrender1 \
39
  python-is-python3 \
40
  python3.10-dev \
41
  python3-pip \
 
42
  wget \
43
  && rm -rf /var/lib/apt/lists/*
44
 
@@ -49,9 +54,11 @@ USER ${USER_NAME}
49
  WORKDIR /app
50
 
51
  RUN pip install torch==2.2.1 torchvision==0.17.1 torchaudio==2.2.1 --index-url https://download.pytorch.org/whl/cu121
 
 
52
 
53
  COPY --chown=${USER_NAME} ./requirements.txt requirements.txt
54
  RUN pip install --no-cache-dir --upgrade -r requirements.txt
55
 
56
  COPY --chown=${USER_NAME} . /app
57
- CMD ["python", "app.py", "--host", "0.0.0.0", "--port", "7860"]
 
28
  RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
29
  build-essential \
30
  curl \
31
+ cmake \
32
  git \
33
+ git-lfs \
34
+ ffmpeg \
35
  libegl1-mesa-dev \
36
  libgl1-mesa-dev \
37
  libgles2-mesa-dev \
38
  libglib2.0-0 \
39
+ libgl1-mesa-glx \
40
  libsm6 \
41
  libxext6 \
42
  libxrender1 \
43
  python-is-python3 \
44
  python3.10-dev \
45
  python3-pip \
46
+ rsync \
47
  wget \
48
  && rm -rf /var/lib/apt/lists/*
49
 
 
54
  WORKDIR /app
55
 
56
  RUN pip install torch==2.2.1 torchvision==0.17.1 torchaudio==2.2.1 --index-url https://download.pytorch.org/whl/cu121
57
+ RUN pip install --no-cache-dir datasets "huggingface-hub>=0.19" "hf-transfer>=0.1.4" "protobuf<4" "click<8.1" "pydantic~=1.0"
58
+ RUN pip install --no-cache-dir gradio[oauth]==4.44.1 "uvicorn>=0.14.0" spaces
59
 
60
  COPY --chown=${USER_NAME} ./requirements.txt requirements.txt
61
  RUN pip install --no-cache-dir --upgrade -r requirements.txt
62
 
63
  COPY --chown=${USER_NAME} . /app
64
+ CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]