update
This commit is contained in:
parent
3547ab677c
commit
14df26ab8f
@ -12,8 +12,10 @@ RUN apt-get update && apt-get install -y \
|
|||||||
# 复制项目文件
|
# 复制项目文件
|
||||||
COPY . /app/
|
COPY . /app/
|
||||||
|
|
||||||
# 创建虚拟环境
|
# 创建虚拟环境, 先判断是否存在
|
||||||
RUN python -m venv venv
|
RUN if [ ! -d "venv" ]; then \
|
||||||
|
python -m venv venv; \
|
||||||
|
fi
|
||||||
|
|
||||||
# 激活虚拟环境
|
# 激活虚拟环境
|
||||||
RUN source venv/bin/activate
|
RUN source venv/bin/activate
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user