1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
| ARG UBUNTU_VERSION=16.04 ARG ARCH= ARG CUDA=10.1 FROM nvidia/cuda${ARCH:+-$ARCH}:${CUDA}-base-ubuntu${UBUNTU_VERSION} as base ARG ARCH ARG CUDA ARG CUDNN=7.6.4.38-1 ARG CUDNN_MAJOR_VERSION=7 ARG LIB_DIR_PREFIX=x86_64 ARG LIBNVINFER=6.0.1-1 ARG LIBNVINFER_MAJOR_VERSION=6
SHELL ["/bin/bash", "-c"]
RUN sed -i s:/archive.ubuntu.com:/mirrors.aliyun.com/ubuntu:g /etc/apt/sources.list;\ sed -i s:/archive.ubuntu.com:/mirrors.tuna.tsinghua.edu.cn/ubuntu:g /etc/apt/sources.list && apt-get clean && apt-get -y update --fix-missing;\ apt-get update && apt-get install -y --no-install-recommends \ build-essential \ cuda-command-line-tools-${CUDA/./-} \ libcublas10 \ cuda-cufft-${CUDA/./-} \ cuda-curand-${CUDA/./-} \ cuda-cusolver-${CUDA/./-} \ cuda-cusparse-${CUDA/./-} \ curl \ libcudnn7=${CUDNN}+cuda${CUDA} \ libfreetype6-dev \ libhdf5-serial-dev \ libzmq3-dev \ pkg-config \ software-properties-common \ unzip zip
RUN [[ "${ARCH}" = "ppc64le" ]] || { apt-get update && \ apt-get install -y --no-install-recommends libnvinfer${LIBNVINFER_MAJOR_VERSION}=${LIBNVINFER}+cuda${CUDA} \ libnvinfer-plugin${LIBNVINFER_MAJOR_VERSION}=${LIBNVINFER}+cuda${CUDA} \ && apt-get clean \ && rm -rf /var/lib/apt/lists/*; }
ENV LD_LIBRARY_PATH /usr/local/cuda/extras/CUPTI/lib64:/usr/local/cuda/lib64:/ln:/usr/cuda_files:$LD_LIBRARY_PATH ARG USE_PYTHON_3_NOT_2 ARG _PY_SUFFIX=${USE_PYTHON_3_NOT_2:+3} ARG PIP=pip3 ARG TF_PACKAGE=tensorflow-gpu ARG TF_PACKAGE_VERSION=2.0.0 ENV LANG C.UTF-8 COPY huanjin.txt /root/huanjin.txt COPY hadoop /hadoop COPY hive_client /hive_client
RUN ln -s /usr/local/cuda/lib64/stubs/libcuda.so /usr/local/cuda/lib64/stubs/libcuda.so.1 \ && echo "/usr/local/cuda/lib64/stubs" > /etc/ld.so.conf.d/z-cuda-stubs.conf \ && ldconfig;\ apt-get update && apt-get install -y \ python3.5 \ python3-pip \ gcc \ libkrb5-dev \ lrzsz \ libsasl2-dev \ libsasl2-2 \ libsasl2-modules-gssapi-mit \ openjdk-8-* RUN ${PIP} --no-cache-dir install --upgrade -i https://pypi.douban.com/simple \ pip \ setuptools;\ ln -s $(which ${PYTHON}) /usr/local/bin/python;\ ${PIP} install ${TF_PACKAGE}${TF_PACKAGE_VERSION:+==${TF_PACKAGE_VERSION}} -i https://pypi.douban.com/simple;\ ${PIP} install -r /root/huanjin.txt -i https://pypi.douban.com/simple;\ mkdir /ln;ln -s /usr/local/cuda-10.1/targets/x86_64-linux/lib/libcudart.so.10.1 /ln/libcudart.so.10.0;ln -s /usr/lib64/stubs/libcublas.so /ln/libcublas.so.10.0;ln -s /usr/local/cuda-10.1/targets/x86_64-linux/lib/libcufft.so.10 /ln/libcufft.so.10.0;ln -s /usr/local/cuda-10.1/targets/x86_64-linux/lib/libcurand.so.10 /ln/libcurand.so.10.0;ln -s /usr/local/cuda-10.1/targets/x86_64-linux/lib/libcusolver.so.10 /ln/libcusolver.so.10.0;ln -s /usr/local/cuda-10.1/targets/x86_64-linux/lib/libcusparse.so.10 /ln/libcusparse.so.10.0;ln -s /hadoop/lib/native/libhdfs.so /ln/libhdfs.so;ln -s /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/libjvm.so /ln/libjvm.so ENV PATH /hadoop/bin/:$PATH ENV HADOOP_HOME /hadoop ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64 ENV HOME /root
7.6.5.32-1+ cuda10.2_amd64.deb
|