Spaces:
Sleeping
Sleeping
bronyowl commited on
Commit ·
7502d7a
1
Parent(s): b6d71c0
first commit
Browse files- Dockerfile +17 -0
- README.md +6 -9
Dockerfile
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# 1. 使用官方 Qdrant 镜像作为基础
|
| 2 |
+
FROM qdrant/qdrant:latest
|
| 3 |
+
|
| 4 |
+
# 2. 切换到 root 用户,以便在构建过程中拥有最高权限
|
| 5 |
+
USER root
|
| 6 |
+
|
| 7 |
+
# 3. 【关键改动】
|
| 8 |
+
# - 创建 /qdrant/storage 和 /qdrant/snapshots 目录 (使用 -p 确保父目录存在)
|
| 9 |
+
# - 将整个 /qdrant 目录(及其所有内容)的所有权递归地赋予用户 1000
|
| 10 |
+
# - 这样,无论是 storage、snapshots 还是未来可能需要的其他子目录,qdrant 用户都有权操作。
|
| 11 |
+
RUN mkdir -p /qdrant/storage /qdrant/snapshots && \
|
| 12 |
+
chown -R 1000:1000 /qdrant
|
| 13 |
+
|
| 14 |
+
# 4. 为了安全,将运行时的用户切换回非 root 的 qdrant 用户 (ID 1000)
|
| 15 |
+
USER 1000
|
| 16 |
+
|
| 17 |
+
# 容器启动时,将以拥有 /qdrant 目录完全权限的 qdrant 用户身份运行
|
README.md
CHANGED
|
@@ -1,11 +1,8 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
|
| 5 |
-
colorTo: indigo
|
| 6 |
sdk: docker
|
|
|
|
| 7 |
pinned: false
|
| 8 |
-
|
| 9 |
-
---
|
| 10 |
-
|
| 11 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
|
| 1 |
+
title: Qdrant
|
| 2 |
+
emoji: 🏆
|
| 3 |
+
colorFrom: purple
|
| 4 |
+
colorTo: purple
|
|
|
|
| 5 |
sdk: docker
|
| 6 |
+
app_port: 6333
|
| 7 |
pinned: false
|
| 8 |
+
short_description: Qdrant_On_HuggingFace
|
|
|
|
|
|
|
|
|