def test_psxevars_false(self):
        """psxevars is false"""
        psxe_rt = intel_psxe_runtime(eula=True,
                                     psxevars=False,
                                     version='2019.5-281')
        self.assertEqual(
            str(psxe_rt),
            r'''# Intel Parallel Studio XE runtime version 2019.5-281
RUN apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        apt-transport-https \
        ca-certificates \
        gcc \
        gnupg \
        man-db \
        openssh-client \
        wget && \
    rm -rf /var/lib/apt/lists/*
RUN wget -qO - https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2019.PUB | apt-key add - && \
    echo "deb https://apt.repos.intel.com/2019 intel-psxe-runtime main" >> /etc/apt/sources.list.d/hpccm.list && \
    apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends aptitude && \
    aptitude install -y --without-recommends -o Aptitude::ProblemResolver::SolutionCost='100*canceled-actions,200*removals' \
        intel-psxe-runtime=2019.5-281 && \
    rm -rf /var/lib/apt/lists/*
ENV DAALROOT=/opt/intel/psxe_runtime/linux/daal \
    FI_PROVIDER_PATH=/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/lib/prov \
    IPPROOT=/opt/intel/psxe_runtime/linux/ipp \
    I_MPI_ROOT=/opt/intel/psxe_runtime/linux/mpi \
    LD_LIBRARY_PATH=/opt/intel/psxe_runtime/linux/daal/lib/intel64:/opt/intel/psxe_runtime/linux/compiler/lib/intel64_lin:/opt/intel/psxe_runtime/linux/compiler/lib/intel64_lin:/opt/intel/psxe_runtime/linux/ipp/lib/intel64:/opt/intel/psxe_runtime/linux/mkl/lib/intel64:/opt/intel/psxe_runtime/linux/mpi/intel64/lib:/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/lib:/opt/intel/psxe_runtime/linux/tbb/lib/intel64/gcc4.7:$LD_LIBRARY_PATH \
    MKLROOT=/opt/intel/psxe_runtime/linux/mkl \
    PATH=/opt/intel/psxe_runtime/linux/mpi/intel64/bin:/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/bin:$PATH'''
        )
Ejemplo n.º 2
0
    def test_psxevars_false(self):
        """psxevars is false"""
        psxe_rt = intel_psxe_runtime(eula=True, psxevars=False)
        self.assertEqual(str(psxe_rt),
r'''# Intel Parallel Studio XE runtime version 2019
RUN apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        apt-transport-https \
        ca-certificates \
        gcc \
        gnupg \
        man-db \
        openssh-client \
        wget && \
    rm -rf /var/lib/apt/lists/*
RUN wget -qO - https://apt.repos.intel.com/2019/GPG-PUB-KEY-INTEL-PSXE-RUNTIME-2019 | apt-key add - && \
    echo "deb https://apt.repos.intel.com/2019 intel-psxe-runtime main" >> /etc/apt/sources.list.d/hpccm.list && \
    apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        intel-psxe-runtime && \
    rm -rf /var/lib/apt/lists/*
ENV DAALROOT=/opt/intel/psxe_runtime/linux/daal \
    FI_PROVIDER_PATH=/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/lib/prov \
    IPPROOT=/opt/intel/psxe_runtime/linux/ipp \
    I_MPI_ROOT=/opt/intel/psxe_runtime/linux/mpi \
    LD_LIBRARY_PATH=/opt/intel/psxe_runtime/linux/daal/lib/intel64:/opt/intel/psxe_runtime/linux/compiler/lib/intel64_lin:/opt/intel/psxe_runtime/linux/compiler/lib/intel64_lin:/opt/intel/psxe_runtime/linux/ipp/lib/intel64:/opt/intel/psxe_runtime/linux/mkl/lib/intel64:/opt/intel/psxe_runtime/linux/mpi/intel64/lib:/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/lib:/opt/intel/psxe_runtime/linux/tbb/lib/intel64/gcc4.7:$LD_LIBRARY_PATH \
    MKLROOT=/opt/intel/psxe_runtime/linux/mkl \
    PATH=/opt/intel/psxe_runtime/linux/mpi/intel64/bin:/opt/intel/psxe_runtime/linux/mpi/intel64/libfabric/bin:$PATH''')
    def test_defaults_eula(self):
        """eula"""
        psxe_rt = intel_psxe_runtime(eula=True)
        self.assertEqual(
            str(psxe_rt),
            r'''# Intel Parallel Studio XE runtime version 2020.0-008
RUN apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        apt-transport-https \
        ca-certificates \
        gcc \
        gnupg \
        man-db \
        openssh-client \
        wget && \
    rm -rf /var/lib/apt/lists/*
RUN wget -qO - https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS-2020.PUB | apt-key add - && \
    echo "deb https://apt.repos.intel.com/2020 intel-psxe-runtime main" >> /etc/apt/sources.list.d/hpccm.list && \
    apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends aptitude && \
    aptitude install -y --without-recommends -o Aptitude::ProblemResolver::SolutionCost='100*canceled-actions,200*removals' \
        intel-psxe-runtime=2020.0-008 && \
    rm -rf /var/lib/apt/lists/*
RUN echo "source /opt/intel/psxe_runtime/linux/bin/psxevars.sh intel64" >> /etc/bash.bashrc'''
        )
    def test_component_off(self):
        """disable one of the runtimes"""
        psxe_rt = intel_psxe_runtime(daal=False,
                                     eula=True,
                                     version='2019.5-281')
        self.assertEqual(
            str(psxe_rt),
            r'''# Intel Parallel Studio XE runtime version 2019.5-281
RUN yum install -y \
        man-db \
        openssh-clients \
        which && \
    rm -rf /var/cache/yum/*
RUN yum install -y nextgen-yum4 && \
    rpm --import https://yum.repos.intel.com/2019/setup/RPM-GPG-KEY-intel-psxe-runtime-2019 && \
    yum install -y yum-utils && \
    yum-config-manager --add-repo https://yum.repos.intel.com/2019/setup/intel-psxe-runtime-2019.repo && \
    yum4 install -y \
        intel-icc-runtime-64bit-2019.5-281 \
        intel-ifort-runtime-64bit-2019.5-281 \
        intel-ipp-runtime-64bit-2019.5-281 \
        intel-mkl-runtime-64bit-2019.5-281 \
        intel-mpi-runtime-64bit-2019.5-281 \
        intel-tbb-runtime-64bit-2019.5-281 && \
    rm -rf /var/cache/yum/*
RUN echo "source /opt/intel/psxe_runtime/linux/bin/psxevars.sh intel64" >> /etc/bashrc'''
        )
Ejemplo n.º 5
0
 def runtime(self, _from='0'):
     """Install the runtime from a full build in a previous stage"""
     return str(intel_psxe_runtime(daal=self.__daal,
                                   eula=self.__eula,
                                   icc=self.__icc,
                                   ifort=self.__ifort,
                                   ipp=self.__ipp,
                                   mkl=self.__mkl,
                                   mpi=self.__mpi,
                                   tbb=self.__tbb,
                                   version=self.__runtime_version))
Ejemplo n.º 6
0
    def test_defaults_eula(self):
        """eula"""
        psxe_rt = intel_psxe_runtime(eula=True)
        self.assertEqual(str(psxe_rt),
r'''# Intel Parallel Studio XE runtime version 2019
RUN apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        apt-transport-https \
        ca-certificates \
        gcc \
        gnupg \
        man-db \
        openssh-client \
        wget && \
    rm -rf /var/lib/apt/lists/*
RUN wget -qO - https://apt.repos.intel.com/2019/GPG-PUB-KEY-INTEL-PSXE-RUNTIME-2019 | apt-key add - && \
    echo "deb https://apt.repos.intel.com/2019 intel-psxe-runtime main" >> /etc/apt/sources.list.d/hpccm.list && \
    apt-get update -y && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        intel-psxe-runtime && \
    rm -rf /var/lib/apt/lists/*
RUN echo "source /opt/intel/psxe_runtime/linux/bin/psxevars.sh intel64" >> /etc/bash.bashrc''')
Ejemplo n.º 7
0
 def test_defaults(self):
     """Default intel_psxe_runtime building block, no eula agreement"""
     with self.assertRaises(RuntimeError):
         psxe_rt = intel_psxe_runtime()
         str(psxe_rt)