feat: 修复报错
This commit is contained in:
24
python-app/Dockerfile
Normal file
24
python-app/Dockerfile
Normal file
@@ -0,0 +1,24 @@
|
||||
ARG DOCKER_MIRROR_PREFIX=m.daocloud.io/docker.io/library
|
||||
FROM ${DOCKER_MIRROR_PREFIX}/python:3.11-slim-bookworm
|
||||
|
||||
ENV PIP_INDEX_URL=https://mirrors.aliyun.com/pypi/simple/ \
|
||||
PIP_TRUSTED_HOST=mirrors.aliyun.com \
|
||||
PYTHONDONTWRITEBYTECODE=1 \
|
||||
PYTHONUNBUFFERED=1
|
||||
|
||||
RUN sed -i 's|deb.debian.org|mirrors.aliyun.com|g' /etc/apt/sources.list.d/debian.sources \
|
||||
&& sed -i 's|security.debian.org|mirrors.aliyun.com|g' /etc/apt/sources.list.d/debian.sources \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
build-essential \
|
||||
tzdata \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY requirements.txt ./
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
|
||||
COPY app ./app
|
||||
|
||||
CMD ["python", "app/backtest_runner.py", "--help"]
|
||||
Reference in New Issue
Block a user