yangtb24 commited on
Commit
d5f37b6
·
verified ·
1 Parent(s): cf63fc8

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +0 -17
Dockerfile CHANGED
@@ -1,23 +1,6 @@
1
- # 使用官方 Python 运行时作为父镜像
2
  FROM python:3.12-rc-slim-buster
3
-
4
- # 设置工作目录为 /app
5
  WORKDIR /app
6
-
7
- # 将当前目录下的 requirements.txt 复制到容器的 /app/requirements.txt 中
8
- COPY requirements.txt /app/
9
-
10
- # 安装 requirements.txt 中指定的任何所需软件包
11
  RUN pip install --no-cache-dir -r requirements.txt
12
-
13
- # 将当前目录下的其余文件复制到容器的 /app 中
14
  COPY . /app/
15
-
16
- # 使端口 7860 可供此容器外的世界使用
17
  EXPOSE 7860
18
-
19
- # 设置环境变量 PORT,以适应 Hugging Face Space 的要求
20
- ENV PORT=7860
21
-
22
- # 在容器启动时运行 app.py
23
  CMD ["python", "app.py"]
 
 
1
  FROM python:3.12-rc-slim-buster
 
 
2
  WORKDIR /app
 
 
 
 
 
3
  RUN pip install --no-cache-dir -r requirements.txt
 
 
4
  COPY . /app/
 
 
5
  EXPOSE 7860
 
 
 
 
 
6
  CMD ["python", "app.py"]