From f26ffba20230c19dc2031b3e4a91aac012bbbd18 Mon Sep 17 00:00:00 2001 From: Liangcai Li Date: Tue, 15 Sep 2020 21:50:14 +0800 Subject: [PATCH] Update the IT Dockerfile to reduce the image size (#766) - Assembled all the installations in one RUN - Cleaned the conda cache files after all the installations done - Removed the duplicate python3.6 Signed-off-by: Firestarman --- jenkins/Dockerfile.integration.centos7 | 27 +++++++++++--------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/jenkins/Dockerfile.integration.centos7 b/jenkins/Dockerfile.integration.centos7 index d2a4bfb46a3..9612ad60430 100644 --- a/jenkins/Dockerfile.integration.centos7 +++ b/jenkins/Dockerfile.integration.centos7 @@ -26,9 +26,7 @@ FROM nvidia/cuda:${CUDA_VER}-runtime-centos7 #Install java-8, maven, docker image RUN yum update -y && \ yum install -y centos-release-scl && \ - yum install -y java-1.8.0-openjdk-devel \ - wget rh-python36 - + yum install -y java-1.8.0-openjdk-devel wget # The default mvn verision is 3.05 on centos7 docker container. # The plugin: net.alchim31.maven requires a higher mvn version. @@ -38,27 +36,24 @@ RUN wget ${URM_URL}/org/apache/maven/apache-maven/3.6.3/apache-maven-3.6.3-bin.t tar xzvf $MAVEN_HOME-bin.tar.gz -C /usr/local && \ rm -f $MAVEN_HOME-bin.tar.gz -ENV PATH "$MAVEN_HOME/bin:/opt/rh/rh-python36/root/usr/bin/:$PATH" +ENV PATH "$MAVEN_HOME/bin:$PATH" RUN wget --quiet https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh && \ /bin/bash ~/miniconda.sh -b -p /opt/conda -RUN . /opt/conda/bin/activate && \ - conda init - ENV PATH="/opt/conda/bin:${PATH}" -RUN conda --version +RUN . /opt/conda/bin/activate && \ + conda init && \ + conda --version ARG CUDA_TOOLKIT_VER=10.1 -RUN conda install -c rapidsai -c nvidia -c conda-forge \ - -c defaults cudf=0.15 python=3.7 cudatoolkit=${CUDA_TOOLKIT_VER} - -RUN conda install spacy && \ - python -m spacy download en_core_web_sm - -RUN conda install -c anaconda pytest requests pandas pyarrow -RUN conda install -c conda-forge sre_yield +RUN conda install -y -c rapidsai -c nvidia -c conda-forge -c defaults cudf=0.15 python=3.7 cudatoolkit=${CUDA_TOOLKIT_VER} && \ + conda install -y spacy && \ + python -m spacy download en_core_web_sm && \ + conda install -y -c anaconda pytest requests pandas pyarrow && \ + conda install -y -c conda-forge sre_yield && \ + conda clean -ay # Set ENV for mvn ENV JAVA_HOME "/usr/lib/jvm/java-1.8.0-openjdk"