1
0
Fork 0
onnx-web/api/Containerfile.cpu.buster

38 lines
824 B
Plaintext

FROM docker.io/python:3.10-buster
WORKDIR /onnx-web/api
RUN apt-get -y update \
&& apt-get install -y ffmpeg libsm6 libxext6 \
&& rm -rf /var/lib/apt/lists/*
RUN pip3 install virtualenv --upgrade
RUN python3 -m venv onnx_env
ENV PATH="/onnx-web/api/onnx_env/bin:$PATH"
RUN pip3 install pip --upgrade
COPY api/requirements/ /onnx-web/api/requirements/
RUN pip3 install -r requirements/cpu.txt --no-cache-dir
RUN pip3 install -r requirements/base.txt --no-cache-dir
COPY api/onnx_web/ /onnx-web/api/onnx_web/
COPY api/launch.sh api/logging.yaml api/params.json /onnx-web/api/
COPY api/schemas/ /onnx-web/api/schemas/
COPY models/extras.json /onnx-web/models/
ENV ONNX_WEB_BUNDLE_PATH="/onnx-web/gui"
COPY gui/out/ /onnx-web/gui/
ENV ONNX_WEB_DEFAULT_PLATFORM="cpu"
CMD [ "sh", "-c", "/onnx-web/launch.sh" ]