Skip to content

Commit 9e03adf

Browse files
committed
替换为 uv 管理
1 parent d4567b5 commit 9e03adf

9 files changed

+880
-954
lines changed

Dockerfile

+3-12
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,9 @@
1-
FROM nvidia/cuda:12.2.0-runtime-ubuntu20.04
2-
3-
ENV DEBIAN_FRONTEND=noninteractive
4-
5-
RUN sed -i 's/deb.debian.org/mirrors.ustc.edu.cn/g' /etc/apt/sources.list && \
6-
sed -i 's/security.debian.org/mirrors.ustc.edu.cn/g' /etc/apt/sources.list && \
7-
echo "开始安装python依赖环境" && apt-get update -y && apt install software-properties-common python3-dev build-essential git -y && add-apt-repository ppa:deadsnakes/ppa -y && \
8-
echo "开始安装python3.10" && apt-get install -y python3.10 curl && curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py && python3.10 get-pip.py && \
9-
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple && \
10-
ln -sf $(which python3.10) /usr/local/bin/python && \
11-
apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
1+
FROM docker.rainbond.cc/506610466/cuda:12.2.0-runtime-ubuntu20.04-uv
122

133
COPY ./ /gpt_server
144
WORKDIR /gpt_server
155

16-
RUN sh install.sh && pip cache purge
6+
RUN uv venv --seed && uv sync && uv cache clean && \
7+
echo '[[ -f .venv/bin/activate ]] && source .venv/bin/activate' >> ~/.bashrc
178

189
CMD ["/bin/bash"]

Dockerfile.copy

-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
FROM docker.rainbond.cc/506610466/gpt_server:latest
22

3-
RUN rm -rf /gpt_server
4-
53
COPY ./ /gpt_server
64

75
WORKDIR /gpt_server
86

9-
# RUN pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple && sh install.sh && pip cache purge && ln -sf $(which python3.10) /usr/local/bin/python
10-
117
CMD ["/bin/bash"]

Dockerfile.copy_test

-9
This file was deleted.

Dockerfile_test

-9
This file was deleted.

docker-compose.yml

-26
This file was deleted.
File renamed without changes.

install.sh

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
pip install -r requirements.txt
2-
pip install --force-reinstall lmdeploy==0.6.2 --no-deps
1+
pip install -r requirements.txt --no-deps

0 commit comments

Comments
 (0)