Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker image maintenance #432

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/workflows/docker-build-env.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,18 @@ jobs:
workdir: tools/docker
dockerfile: Dockerfile.build-env-latest-gcc
tags: "latest"

docker-build-env-rocm:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
- name: Publish Gitlab Image
uses: elgohr/[email protected]
with:
name: dbcsr/build-env-rocm-ubuntu-20.04
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
workdir: tools/docker
dockerfile: Dockerfile.build-env-rocm
tags: "latest"
2 changes: 1 addition & 1 deletion .github/workflows/testing-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
build-on-rocm:
runs-on: ubuntu-latest
container:
image: shoshijak/build-env-rocm:1.0
image: dbcsr/build-env-rocm-ubuntu-20.04:latest

strategy:
matrix:
Expand Down
4 changes: 2 additions & 2 deletions tools/docker/Dockerfile.build-env-latest-gcc
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ ENV LANG en_US.utf8
RUN ln -sf python3 /usr/bin/python

# Debian is at CMake 3.13 and Ninja 1.8
ARG cmake_version=3.17.0
ARG ninja_version=1.10.0
ARG cmake_version=3.17.5
ARG ninja_version=1.10.2

RUN set -ex ; \
curl -LsS https://github.com/Kitware/CMake/releases/download/v${cmake_version}/cmake-${cmake_version}-Linux-x86_64.tar.gz | tar --strip-components=1 -xz -C /usr/local ; \
Expand Down
55 changes: 18 additions & 37 deletions tools/docker/Dockerfile.build-env-rocm
Original file line number Diff line number Diff line change
@@ -1,43 +1,24 @@
FROM rocm/dev-ubuntu-18.04:latest
FROM rocm/dev-ubuntu-20.04:4.0.1

ENV DEBIAN_FRONTEND=noninteractive

# install compilers, libraries & co
RUN apt-get update
RUN apt-get install -y \
locales \
gfortran \
gcc-7 \
g++-7 \
llvm-7-dev \
llvm-7-tools \
mpich \
libomp-7-dev \
RUN apt-get update -qq \
&& apt-get install --no-install-recommends -qq \
ca-certificates \
gfortran g++ gcc \
git \
hipblas \
libmpich-dev \
libopenblas-dev \
wget

# install rocm libraries
RUN wget -q -O - http://repo.radeon.com/rocm/rocm.gpg.key | sudo apt-key add -
RUN echo 'deb [arch=amd64] http://repo.radeon.com/rocm/apt/debian/ xenial main' | sudo tee /etc/apt/sources.list.d/rocm.list
RUN apt-get update
RUN apt-get install -y \
rocm-dev \
libopenblas-openmp-dev \
mpich \
ninja-build \
rocblas \
rocsolver \
hipblas

# install git 2.18+
RUN apt-get install -y software-properties-common
RUN add-apt-repository ppa:git-core/ppa
RUN apt-get install -y git

# install ninja
RUN apt-get install -y wget
RUN wget https://github.com/Kitware/ninja/releases/download/v1.10.0.gfb670.kitware.jobserver-1/ninja-1.10.0.gfb670.kitware.jobserver-1_x86_64-linux-gnu.tar.gz
RUN tar -xzvf ninja-1.10.0.gfb670.kitware.jobserver-1_x86_64-linux-gnu.tar.gz
ENV PATH="/ninja-1.10.0.gfb670.kitware.jobserver-1_x86_64-linux-gnu:${PATH}"

# install cmake
RUN wget https://github.com/Kitware/CMake/releases/download/v3.17.0/cmake-3.17.0-Linux-x86_64.tar.gz
RUN tar -xzvf cmake-3.17.0-Linux-x86_64.tar.gz
ENV PATH="/cmake-3.17.0-Linux-x86_64/bin:${PATH}"
wget \
python3-pip \
&& rm -rf /var/lib/apt/lists/* \
&& wget -qO- "https://cmake.org/files/v3.17/cmake-3.17.5-Linux-x86_64.tar.gz" | \
tar --strip-components=1 -xz -C /usr/local \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just discovered this one here: https://apt.kitware.com/ ... what do you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm yeah, I think it can't hurt to install a specific version and I'm too lazy to figure out how you would pin it with apt

&& pip3 install fypp

2 changes: 1 addition & 1 deletion tools/docker/Dockerfile.build-env-ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ ENV LANG en_US.utf8
RUN ln -s python3 /usr/bin/python

ARG libxsmm_version=1.16.1
ARG cmake_version=3.17.0
ARG cmake_version=3.17.5

RUN set -ex && \
pip3 install \
Expand Down