Spaces:
Sleeping
Sleeping
XxxX
Browse files- Dockerfile +28 -0
- README.md +5 -6
Dockerfile
ADDED
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# 使用Node.js基础镜像
|
2 |
+
FROM node:alpine
|
3 |
+
|
4 |
+
# 设置大陆时区
|
5 |
+
ENV TZ Asia/Shanghai
|
6 |
+
|
7 |
+
# 设置工作目录
|
8 |
+
WORKDIR /drive
|
9 |
+
|
10 |
+
# 安装Git
|
11 |
+
RUN apk update && apk add --no-cache git
|
12 |
+
|
13 |
+
# 克隆项目
|
14 |
+
RUN git clone --depth=1 https://github.com/Zyy955/Lain-drive .
|
15 |
+
|
16 |
+
# 修改域名
|
17 |
+
RUN sed -i 's/^baseUrl:.*/baseUrl: https:\/\/hanxuan-drive.hf.space/' config/defSet/config.yaml
|
18 |
+
|
19 |
+
# 赋予权限/归递
|
20 |
+
RUN chmod -R 777 /tmp
|
21 |
+
RUN chmod -R 777 /drive
|
22 |
+
|
23 |
+
# 安装依赖
|
24 |
+
RUN npm install -g pnpm
|
25 |
+
RUN pnpm install
|
26 |
+
|
27 |
+
# 启动!
|
28 |
+
CMD ["node", "app.js"]
|
README.md
CHANGED
@@ -1,10 +1,9 @@
|
|
1 |
---
|
2 |
title: Drive
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
-
|
9 |
-
|
10 |
-
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
|
|
1 |
---
|
2 |
title: Drive
|
3 |
+
emoji: 💻
|
4 |
+
colorFrom: purple
|
5 |
+
colorTo: pink
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
+
app_port: 2957
|
9 |
+
---
|
|