Spaces:
Runtime error
Runtime error
update Dockerfile
Browse files- Dockerfile +15 -0
Dockerfile
ADDED
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
FROM python:3.10-slim
|
2 |
+
|
3 |
+
# 安装 Node.js
|
4 |
+
RUN apt-get update && apt-get install -y nodejs npm && rm -rf /var/lib/apt/lists/* /tmp/*
|
5 |
+
|
6 |
+
# 安装 Python 依赖
|
7 |
+
COPY requirements.txt .
|
8 |
+
RUN pip install -r requirements.txt
|
9 |
+
|
10 |
+
# 复制应用代码
|
11 |
+
COPY . /app
|
12 |
+
WORKDIR /app
|
13 |
+
|
14 |
+
# 设置应用启动命令
|
15 |
+
CMD ["python", "app.py"]
|