增加新cuda版本的gpu镜像

This commit is contained in:
xiaoman.gao@extremevision.com.cn 2024-06-11 13:53:44 +08:00
parent b03fdd7495
commit ba369c50dc
2 changed files with 15 additions and 6 deletions

View File

@ -1,14 +1,23 @@
set -ex
TARGETARCH=amd64
hubhost=ccr.ccs.tencentyun.com/cube-studio
base_image=nvidia/cuda:11.8.0-cudnn8-runtime-ubuntu20.04
TARGETARCH=amd64
docker build -t $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-$TARGETARCH --build-arg FROM_IMAGES=$base_image -f cuda/Dockerfile .
docker build -t $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.7-$TARGETARCH --build-arg FROM_IMAGES=$hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-$TARGETARCH --build-arg PYTHON_VERSION=python3.7 -f cuda/python/Dockerfile .
docker build -t $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.8-$TARGETARCH --build-arg FROM_IMAGES=$hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-$TARGETARCH --build-arg PYTHON_VERSION=python3.8 -f cuda/python/Dockerfile .
docker build -t $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9-$TARGETARCH --build-arg FROM_IMAGES=$hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-$TARGETARCH --build-arg PYTHON_VERSION=python3.9 -f cuda/python/Dockerfile .
docker push $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-$TARGETARCH
docker push $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.7-$TARGETARCH
docker push $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.8-$TARGETARCH
docker push $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9-$TARGETARCH
# docker manifest create $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9 $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9-amd64 $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9-arm64 && docker manifest push $hubhost/ubuntu-gpu:cuda11.8.0-cudnn8-python3.9
base_image=nvidia/cuda:12.1.0-cudnn8-runtime-ubuntu20.04
docker build -t $hubhost/ubuntu-gpu:cuda12.1.0-cudnn8-$TARGETARCH --build-arg FROM_IMAGES=$base_image -f cuda/Dockerfile .
docker build -t $hubhost/ubuntu-gpu:cuda12.1.0-cudnn8-python3.9-$TARGETARCH --build-arg FROM_IMAGES=$hubhost/ubuntu-gpu:cuda12.2.2-cudnn8-$TARGETARCH --build-arg PYTHON_VERSION=python3.9 -f cuda/python/Dockerfile .
docker push $hubhost/ubuntu-gpu:cuda12.1.0-cudnn8-$TARGETARCH
docker push $hubhost/ubuntu-gpu:cuda12.1.0-cudnn8-python3.9-$TARGETARCH

View File

@ -5,7 +5,7 @@ ARG PYTHON_VERSION
# 安装python
RUN add-apt-repository -y ppa:deadsnakes/ppa && apt update && apt install -y libsasl2-dev libpq-dev python3-pip $PYTHON_VERSION-distutils
RUN set -x; rm -rf /usr/bin/python; apt install -y --fix-missing ${PYTHON_VERSION} && ln -s /usr/bin/${PYTHON_VERSION} /usr/bin/python
RUN set -x; rm -rf /usr/bin/python /usr/bin/python3; apt install -y --fix-missing ${PYTHON_VERSION} && ln -s /usr/bin/${PYTHON_VERSION} /usr/bin/python && ln -s /usr/bin/${PYTHON_VERSION} /usr/bin/python3
RUN bash -c "wget https://bootstrap.pypa.io/get-pip.py && python get-pip.py --ignore-installed" \
&& rm -rf /usr/bin/pip && ln -s /usr/bin/pip3 /usr/bin/pip