Created
January 13, 2017 21:00
-
-
Save qharlie/faa3d84484c93594f1790138aac88ee4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:16.04 | |
LABEL maintainer "Charlie" | |
LABEL com.nvidia.volumes.needed="nvidia_driver" | |
ENV DEBIAN_FRONTEND noninteractive | |
RUN NVIDIA_GPGKEY_SUM=d1be581509378368edeec8c1eb2958702feedf3bc3d17011adbf24efacce4ab5 && \ | |
NVIDIA_GPGKEY_FPR=ae09fe4bbd223a84b2ccfce3f60f4b3d7fa2af80 && \ | |
apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/7fa2af80.pub && \ | |
apt-key adv --export --no-emit-version -a $NVIDIA_GPGKEY_FPR | tail -n +5 > cudasign.pub && \ | |
echo "$NVIDIA_GPGKEY_SUM cudasign.pub" | sha256sum -c --strict - && rm cudasign.pub && \ | |
echo "deb http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64 /" > /etc/apt/sources.list.d/cuda.list | |
ENV CUDA_VERSION 8.0 | |
LABEL com.nvidia.cuda.version="8.0" | |
ENV CUDA_PKG_VERSION 8-0=8.0.44-1 | |
RUN apt-get update && apt-get install --yes --no-install-recommends \ | |
cuda-nvrtc-$CUDA_PKG_VERSION \ | |
cuda-nvgraph-$CUDA_PKG_VERSION \ | |
cuda-cusolver-$CUDA_PKG_VERSION \ | |
cuda-cublas-$CUDA_PKG_VERSION \ | |
cuda-cufft-$CUDA_PKG_VERSION \ | |
cuda-curand-$CUDA_PKG_VERSION \ | |
cuda-cusparse-$CUDA_PKG_VERSION \ | |
cuda-npp-$CUDA_PKG_VERSION \ | |
cuda-cudart-$CUDA_PKG_VERSION \ | |
cuda-toolkit-$CUDA_VERSION \ | |
cuda-drivers cuda-samples-8-0 && \ | |
ln -s cuda-$CUDA_VERSION /usr/local/cuda && \ | |
rm -rf /var/lib/apt/lists/* | |
RUN echo "/usr/local/cuda/lib" >> /etc/ld.so.conf.d/cuda.conf && \ | |
echo "/usr/local/cuda/lib64" >> /etc/ld.so.conf.d/cuda.conf && \ | |
ldconfig | |
RUN echo "/usr/local/nvidia/lib" >> /etc/ld.so.conf.d/nvidia.conf && \ | |
echo "/usr/local/nvidia/lib64" >> /etc/ld.so.conf.d/nvidia.conf | |
ENV PATH /usr/local/nvidia/bin:/usr/local/cuda/bin:${PATH} | |
ENV LD_LIBRARY_PATH /usr/local/nvidia/lib:/usr/local/nvidia/lib64:${LD_LIBRARY_PATH} | |
# Base items for building | |
RUN apt-get update && apt-get install -y mlocate emacs-nox git \ | |
g++ zlib1g-dev make gcc automake autoconf bzip2 wget libtool subversion | |
# Anaconda | |
RUN apt-get update && apt-get install -y mlocate emacs-nox git \ | |
g++ zlib1g-dev make gcc automake autoconf bzip2 wget libtool subversion unzip \ | |
man | |
RUN wget https://repo.continuum.io/archive/Anaconda2-4.2.0-Linux-x86_64.sh -O /anaconda.sh | |
RUN chmod +x /anaconda.sh | |
RUN /anaconda.sh -b -p /opt/anaconda | |
ENV PATH "$PATH:/opt/anaconda/bin" | |
# Now kaldi specific items | |
RUN git clone https://github.com/qorrect/kaldi.git && ln -s -f bash /bin/sh | |
#Now install MKL | |
ENV MKL_INSTALL_DIR l_mkl_2017.0.098 | |
RUN wget http://www.the-charlie.com/l_mkl_2017.0.098.tgz | |
RUN tar xzf /l_mkl_2017.0.098.tgz | |
RUN apt-get update && apt-get install -y cpio | |
RUN cd l_mkl_2017.0.098 && \ | |
sed -i 's/ACCEPT_EULA=decline/ACCEPT_EULA=accept/g' silent.cfg && \ | |
sed -i 's/ACTIVATION_TYPE=exist_lic/ACTIVATION_TYPE=serial_number/g' silent.cfg && \ | |
sed -i 's/#ACTIVATION_SERIAL_NUMBER=snpat/ACTIVATION_SERIAL_NUMBER=33RM-2JRPRX5R/g' silent.cfg && \ | |
./install.sh -s silent.cfg | |
RUN apt-get update && apt-get install -y htop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment