hzhwcmhf commited on
Commit
6bfd42f
·
1 Parent(s): 44b71e3

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +24 -24
Dockerfile CHANGED
@@ -1,24 +1,24 @@
1
- FROM python:3.9
2
-
3
- RUN --mount=target=/root/packages.txt,source=packages.txt sed -i 's http://deb.debian.org http://cdn-aws.deb.debian.org g' /etc/apt/sources.list && sed -i 's http://archive.ubuntu.com http://us-east-1.ec2.archive.ubuntu.com g' /etc/apt/sources.list && sed -i '/security/d' /etc/apt/sources.list && apt-get update && xargs -r -a /root/packages.txt apt-get install -y && rm -rf /var/lib/apt/lists/*
4
-
5
- RUN pip install --no-cache-dir pip==22.3.1 && pip install --no-cache-dir datasets "huggingface-hub>=0.12.1" "protobuf<4" "click<8.1"
6
-
7
- WORKDIR /home/user/app
8
-
9
- RUN sed -i 's http://deb.debian.org http://cdn-aws.deb.debian.org g' /etc/apt/sources.list && sed -i 's http://archive.ubuntu.com http://us-east-1.ec2.archive.ubuntu.com g' /etc/apt/sources.list && sed -i '/security/d' /etc/apt/sources.list && apt-get update && apt-get install -y git git-lfs ffmpeg libsm6 libxext6 cmake libgl1-mesa-glx && rm -rf /var/lib/apt/lists/* && git lfs install
10
-
11
- RUN pip install --no-cache-dir Cython "gradio==3.28.3" "torch==1.10.1" jieba subword-nmt sacremoses transformers
12
-
13
- RUN git clone --recurse-submodules https://github.com/thu-coai/DA-Transformer.git && cd DA-Transformer && pip install -e . && cd dag_search && python3 setup.py build_ext --inplace && pip install -e . && cd ../..
14
-
15
- RUN mkdir -p /home/user && chmod 777 /home/user
16
-
17
- USER user
18
-
19
- ENV HOME=/home/user \
20
- PATH=/home/user/.local/bin:$PATH
21
-
22
- COPY . .
23
-
24
- CMD ["python3", "app.py"]
 
1
+ FROM python:3.9
2
+
3
+ RUN --mount=target=/root/packages.txt,source=packages.txt apt-get update && xargs -r -a /root/packages.txt apt-get install -y
4
+
5
+ RUN pip install --no-cache-dir pip==22.3.1 && pip install --no-cache-dir datasets "huggingface-hub>=0.12.1" "protobuf<4" "click<8.1"
6
+
7
+ WORKDIR /home/user/app
8
+
9
+ RUN apt-get install -y git git-lfs ffmpeg libsm6 libxext6 cmake libgl1-mesa-glx && git lfs install
10
+
11
+ RUN pip install --no-cache-dir Cython "gradio==3.28.3" "torch==1.10.1" jieba subword-nmt sacremoses transformers
12
+
13
+ RUN git clone --recurse-submodules https://github.com/thu-coai/DA-Transformer.git && cd DA-Transformer && pip install -e . && cd dag_search && python3 setup.py build_ext --inplace && pip install -e . && cd ../..
14
+
15
+ RUN mkdir -p /home/user && chmod 777 /home/user
16
+
17
+ USER user
18
+
19
+ ENV HOME=/home/user \
20
+ PATH=/home/user/.local/bin:$PATH
21
+
22
+ COPY . .
23
+
24
+ CMD ["python3", "app.py"]