ee9e74df21
git-subtree-dir: projects/rocprofiler-compute git-subtree-mainline:8a4d7262f8git-subtree-split:d2cec00116
55 regels
2.2 KiB
Docker
55 regels
2.2 KiB
Docker
ARG DISTRO=opensuse/leap
|
|
ARG VERSION=15.3
|
|
FROM ${DISTRO}:${VERSION}
|
|
|
|
ENV HOME /root
|
|
ENV SHELL /bin/bash
|
|
ENV BASH_ENV /etc/bash.bashrc
|
|
ENV DEBIAN_FRONTEND noninteractive
|
|
|
|
WORKDIR /tmp
|
|
SHELL [ "/bin/bash", "-c" ]
|
|
|
|
ENV PATH /usr/local/bin:${PATH}
|
|
ENV LIBRARY_PATH ${LIBRARY_PATH}:/opt/amdgpu/lib64
|
|
|
|
RUN set +e; \
|
|
zypper --non-interactive -i --gpg-auto-import-keys refresh; \
|
|
zypper --non-interactive -i patch; \
|
|
zypper --non-interactive -i patch; \
|
|
zypper --non-interactive -i --gpg-auto-import-keys refresh; \
|
|
exit 0
|
|
|
|
RUN zypper --non-interactive update -y && \
|
|
zypper --non-interactive dist-upgrade -y && \
|
|
zypper --non-interactive install -y -t pattern devel_basis && \
|
|
zypper --non-interactive install -y python3-pip gcc-c++ git dpkg-devel rpm-build wget curl binutils-gold && \
|
|
python3 -m pip install 'cmake==3.28.4'
|
|
|
|
ARG ROCM_VERSION=0.0
|
|
ARG AMDGPU_RPM=latest/sle/15/amdgpu-install-21.50.50000-1.noarch.rpm
|
|
ARG PERL_REPO=SLE_15
|
|
|
|
RUN if [ "${ROCM_VERSION}" != "0.0" ]; then \
|
|
zypper --non-interactive addrepo https://mirrorcache-us.opensuse.org/repositories/devel:/languages:/perl/${PERL_REPO}/devel:languages:perl.repo && \
|
|
zypper --non-interactive --no-gpg-checks install -y https://repo.radeon.com/amdgpu-install/${AMDGPU_RPM} && \
|
|
zypper --non-interactive --gpg-auto-import-keys refresh && \
|
|
zypper --non-interactive install -y rocm-dev rocm-smi-lib roctracer-dev rocprofiler-dev rccl-devel libpciaccess0 && \
|
|
zypper --non-interactive clean --all; \
|
|
fi
|
|
|
|
ARG PYTHON_VERSIONS="6 7 8 9 10 11 12"
|
|
|
|
RUN wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh && \
|
|
bash miniconda.sh -b -p /opt/conda && \
|
|
export PATH="/opt/conda/bin:${PATH}" && \
|
|
conda config --set always_yes yes --set changeps1 no && \
|
|
conda update -c defaults -n base conda && \
|
|
for i in ${PYTHON_VERSIONS}; do conda create -n py3.${i} -c defaults -c conda-forge python=3.${i} pip; done && \
|
|
for i in ${PYTHON_VERSIONS}; do /opt/conda/envs/py3.${i}/bin/python -m pip install numpy perfetto dataclasses; done && \
|
|
conda clean -a -y && \
|
|
conda init
|
|
|
|
WORKDIR /home
|
|
SHELL [ "/bin/bash", "--login", "-c" ]
|