orztv
commited on
Commit
·
7a4fde2
1
Parent(s):
8b17e1c
update
Browse files- Dockerfile +5 -23
Dockerfile
CHANGED
@@ -56,35 +56,17 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
56 |
jq \
|
57 |
netcat-openbsd \
|
58 |
redis-server \
|
59 |
-
# 添加 Qdrant 依赖
|
60 |
-
pkg-config \
|
61 |
-
libssl-dev \
|
62 |
-
# 添加 libclang 依赖
|
63 |
-
llvm-dev \
|
64 |
-
libclang-dev \
|
65 |
-
clang \
|
66 |
&& ln -fs /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
|
67 |
&& dpkg-reconfigure --frontend noninteractive tzdata \
|
68 |
-
#
|
69 |
-
&& curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y \
|
70 |
-
&& . $HOME/.cargo/env \
|
71 |
-
# 设置 Rust 编译配置
|
72 |
-
&& CARGO_PROFILE_RELEASE_BUILD_OVERRIDE_DEBUG=true \
|
73 |
-
# 查找 libclang.so 的位置
|
74 |
-
&& LIBCLANG_PATH=$(find /usr/lib -name libclang.so.* | head -n 1 | xargs dirname) \
|
75 |
-
&& echo "Found libclang at: ${LIBCLANG_PATH}" \
|
76 |
-
# 克隆并编译 Qdrant
|
77 |
&& cd /tmp \
|
78 |
-
&&
|
79 |
-
&&
|
80 |
-
&&
|
81 |
-
&&
|
82 |
-
&& cd / \
|
83 |
-
&& rm -rf /tmp/qdrant \
|
84 |
# 清理
|
85 |
&& apt-get clean \
|
86 |
&& rm -rf /var/lib/apt/lists/* \
|
87 |
-
&& rm -rf $HOME/.cargo/registry \
|
88 |
# 创建虚拟环境并安装 Python 依赖
|
89 |
&& python3 -m venv $VIRTUAL_ENV \
|
90 |
&& $VIRTUAL_ENV/bin/pip install --no-cache-dir --upgrade pip requests yt-dlp \
|
|
|
56 |
jq \
|
57 |
netcat-openbsd \
|
58 |
redis-server \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
59 |
&& ln -fs /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
|
60 |
&& dpkg-reconfigure --frontend noninteractive tzdata \
|
61 |
+
# 下载并安装预编译的 Qdrant
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
62 |
&& cd /tmp \
|
63 |
+
&& curl -L https://github.com/qdrant/qdrant/releases/latest/download/qdrant-linux-x86_64.tar.gz -o qdrant.tar.gz \
|
64 |
+
&& tar xvf qdrant.tar.gz \
|
65 |
+
&& mv qdrant /usr/local/bin/ \
|
66 |
+
&& rm qdrant.tar.gz \
|
|
|
|
|
67 |
# 清理
|
68 |
&& apt-get clean \
|
69 |
&& rm -rf /var/lib/apt/lists/* \
|
|
|
70 |
# 创建虚拟环境并安装 Python 依赖
|
71 |
&& python3 -m venv $VIRTUAL_ENV \
|
72 |
&& $VIRTUAL_ENV/bin/pip install --no-cache-dir --upgrade pip requests yt-dlp \
|