I also tried to build my own image and uploaded it to harbor, but the tasks didn't use the packages from it.
FROM nvidia/cuda:12.4.0-devel-ubuntu22.04
ENV TZ=Europe/Moscow
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
WORKDIR /workspace
RUN apt-get update && apt-get install -y
software-properties-common
curl &&
add-apt-repository ppa:deadsnakes/ppa -y &&
apt-get update && apt-get install -y
python3.11
python3.11-venv
python3.11-dev &&
rm -rf /var/lib/apt/lists/*
RUN curl -sS None | python3.11
RUN update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.11 1
RUN python3.11 -m venv /opt/venv
ENV VIRTUAL_ENV=/opt/venv
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
COPY . .
RUN pip install --upgrade pip
RUN pip install torch --index-url None
RUN pip install clearml --index-url None
RUN pip install -r requirements.txt --index-url None