FROM harbor.4pd.io/inf/base-python3.8-ubuntu:1.1.0 MAINTAINER shiguangchuan@4paradigm.com WORKDIR /workspace COPY ssh-keygen /bin RUN wget -q ftp://ftp.4pd.io/pub/pico/temp/pynini-2.1.6-cp38-cp38-manylinux_2_31_x86_64.whl && pip install pynini-2.1.6-cp38-cp38-manylinux_2_31_x86_64.whl && rm -f pynini-2.1.6-c p38-cp38-manylinux_2_31_x86_64.whl ADD ./requirements.txt /workspace RUN pip install -r ./requirements.txt -i https://nexus.4pd.io/repository/pypi-all/simple --trusted-host nexus.4pd.io --extra-index-url https://mirrors.aliyun.com/pypi/simple/ \ && pip cache purge \ && ssh-keygen -f /workspace/ssh-key-ecdsa -t ecdsa -b 521 -q -N "" ADD . /workspace EXPOSE 80 CMD ["python3", "run_callback.py"] ########################### ## Dockerfile(更新后) #FROM harbor.4pd.io/lab-platform/inf/python:3.9 #WORKDIR /app ## 安装依赖 ##RUN pip install torch librosa flask ##RUN pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/ && \ ## pip cache purge && \ ## pip --default-timeout=1000 install torch librosa flask ## 删除原来的 COPY pytorch_model.bin /app/ #COPY inference.py /app/ # 只需要复制启动脚本 #EXPOSE 80 #CMD ["python", "inference.py"] #################### ##############################更新0731#################################