Spaces:
Runtime error
Runtime error
Commit
·
990b223
1
Parent(s):
f639022
updated dockerifle
Browse files- Dockerfile +44 -28
Dockerfile
CHANGED
@@ -1,33 +1,49 @@
|
|
1 |
-
FROM nvidia/cuda:12.1.
|
2 |
-
|
3 |
-
|
4 |
-
# Combine apt-get update, upgrade, and installation of packages. Clean up in the same layer to reduce image size.
|
5 |
RUN apt-get update && \
|
6 |
apt-get upgrade -y && \
|
7 |
-
apt-get install -y
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
apt-get clean && \
|
10 |
rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
RUN pip install
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
RUN pip install --no-cache-dir -e .
|
32 |
-
|
33 |
-
ENTRYPOINT ["python3.10", "serving.py"]
|
|
|
1 |
+
# FROM nvidia/cuda:12.1.1-cudnn8-devel-ubuntu22.04
|
2 |
+
FROM nvidia/cuda:11.7.1-cudnn8-devel-ubuntu22.04
|
3 |
+
ENV DEBIAN_FRONTEND=noninteractive
|
|
|
4 |
RUN apt-get update && \
|
5 |
apt-get upgrade -y && \
|
6 |
+
apt-get install -y --no-install-recommends \
|
7 |
+
git \
|
8 |
+
git-lfs \
|
9 |
+
wget \
|
10 |
+
curl \
|
11 |
+
# python build dependencies \
|
12 |
+
build-essential \
|
13 |
+
libssl-dev \
|
14 |
+
zlib1g-dev \
|
15 |
+
libbz2-dev \
|
16 |
+
libreadline-dev \
|
17 |
+
libsqlite3-dev \
|
18 |
+
libncursesw5-dev \
|
19 |
+
xz-utils \
|
20 |
+
tk-dev \
|
21 |
+
libxml2-dev \
|
22 |
+
libxmlsec1-dev \
|
23 |
+
libffi-dev \
|
24 |
+
liblzma-dev \
|
25 |
+
# gradio dependencies \
|
26 |
+
ffmpeg \
|
27 |
+
# fairseq2 dependencies \
|
28 |
+
libsndfile-dev && \
|
29 |
apt-get clean && \
|
30 |
rm -rf /var/lib/apt/lists/*
|
31 |
|
32 |
+
RUN useradd -m -u 1000 user
|
33 |
+
USER user
|
34 |
+
ENV HOME=/home/user \
|
35 |
+
PATH=/home/user/.local/bin:${PATH}
|
36 |
+
WORKDIR ${HOME}/app
|
37 |
+
|
38 |
+
RUN curl https://pyenv.run | bash
|
39 |
+
ENV PATH=${HOME}/.pyenv/shims:${HOME}/.pyenv/bin:${PATH}
|
40 |
+
ARG PYTHON_VERSION=3.10.13
|
41 |
+
RUN pyenv install ${PYTHON_VERSION} && \
|
42 |
+
pyenv global ${PYTHON_VERSION} && \
|
43 |
+
pyenv rehash && \
|
44 |
+
pip install --no-cache-dir -U pip setuptools wheel && \
|
45 |
+
git clone https://github.com/fakerybakery/metavoice-src ${HOME}/app/gitrepo && \
|
46 |
+
cp -r ${HOME}/app/gitrepo/* ${HOME}/app
|
47 |
+
RUN pip install packaging && \
|
48 |
+
pip install -r ${HOME}/app/requirements.txt && \
|
49 |
+
pip install -U flash-attn gradio spacy transformers fastapi
|
|
|
|
|
|
|
|