VERSION 0.7
FROM nvidia/cuda:11.8.0-cudnn8-runtime-ubuntu22.04
WORKDIR /code
RUN --mount=type=cache,target=/var/cache/apt \
apt-get update \
&& DEBIAN_FRONTEND=noninteractive TZ=America/New_York apt-get install --no-install-recommends -y fonts-dejavu-core rsync git jq moreutils aria2 python3 python3-venv python3-pip ffmpeg \
libsm6 \
libxext6 \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
ARG DEBIAN_FRONTEND=noninteractive
deps:
RUN --mount=type=cache,target=/cache --mount=type=cache,target=/root/.cache/pip \
aria2c -x 5 --dir /cache --out torch-2.0.1-cp310-cp310-linux_x86_64.whl -c \
https://download.pytorch.org/whl/cu118/torch-2.0.1%2Bcu118-cp310-cp310-linux_x86_64.whl && \
pip install /cache/torch-2.0.1-cp310-cp310-linux_x86_64.whl torchvision --index-url https://download.pytorch.org/whl/cu118
RUN pip3 install wheel
COPY requirements.txt ./
RUN pip wheel -r requirements.txt --wheel-dir=wheels
build:
FROM +deps
COPY x.py x.py
SAVE ARTIFACT x.py /x.py
SAVE ARTIFACT wheels /wheels
docker:
FROM +deps
COPY +build/x.py x.py
COPY +build/wheels wheels
COPY requirements.txt ./
RUN pip install --no-index --find-links=wheels -r requirements.txt
ENTRYPOINT ["python3", "./x.py"]
SAVE IMAGE rockerboo/x:latest
1 failure:
correct / expected / unexpected
1. test_long_run:
(source_file
(block
(version_command
(version_major_minor))
(from_command
(image_spec
(image_name)
(image_tag)))
(workdir_command
(string
(unquoted_string)))
(run_command
(options
(mount
(string
(unquoted_string)
(unquoted_string))))
(line_continuation)
(shell_fragment
(line_continuation)
(line_continuation))))
(ERROR))
)
Thanks
Thanks