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

Upgrade all images #215

Merged
merged 2 commits into from
Apr 19, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 5 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
image: ['debian', 'fedora', 'ubuntu-22.04', 'ubuntu-wo-dependencies']
image:
- debian
- fedora
- ubuntu
- ubuntu-wo-dependencies
steps:
- uses: actions/checkout@main
- name: Build and deploy
Expand Down
17 changes: 10 additions & 7 deletions docker/Dockerfile-debian
Original file line number Diff line number Diff line change
@@ -1,29 +1,32 @@
FROM debian:bullseye AS image_base
RUN echo "deb http://deb.debian.org/debian bullseye-backports main" >> /etc/apt/sources.list && \
apt-get update && \
FROM debian:bookworm AS image_base
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
apt-utils \
build-essential \
curl \
cmake \
ccache \
curl \
cython3 \
gdb \
git \
libboost-dev libboost-serialization-dev libboost-mpi-dev libboost-filesystem-dev libboost-test-dev \
libboost-dev \
libboost-filesystem-dev \
libboost-mpi-dev \
libboost-serialization-dev \
libboost-test-dev \
libfftw3-dev \
libhdf5-openmpi-dev \
libpython3-dev \
openmpi-bin \
python3 \
python3-h5py \
python3-numpy \
python3-packaging \
python3-pip \
python3-scipy \
python3-setuptools \
python3-vtk9 \
vim && \
DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends --target-release bullseye-backports \
cmake && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

Expand Down
5 changes: 4 additions & 1 deletion docker/Dockerfile-fedora
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM fedora:36
FROM fedora:40
RUN dnf -y install \
blas-devel \
boost-devel \
Expand All @@ -7,6 +7,7 @@ RUN dnf -y install \
cmake \
environment-modules \
fftw-devel \
fftw-mpich-devel \
gcc \
gcc-c++ \
gdb \
Expand All @@ -18,8 +19,10 @@ RUN dnf -y install \
python3 \
python3-devel \
python3-Cython \
python3-lxml \
python3-numpy \
python3-scipy \
python3-packaging \
python3-pip \
python3-setuptools \
python3-h5py \
Expand Down
126 changes: 126 additions & 0 deletions docker/Dockerfile-ubuntu
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
FROM ubuntu:noble
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y \
apt-utils \
autoconf \
automake \
build-essential \
ccache \
clang-18 clang-tidy-18 clang-format-18 llvm-18 libclang-rt-18-dev \
cmake \
cmake-format \
curl \
cython3 \
doxygen \
ffmpeg \
gcc-12 g++-12 \
gcc-13 g++-13 \
gdb \
gfortran \
git \
gnupg \
graphviz \
ipython3 \
jq \
jupyter-client \
jupyter-core \
jupyter-nbconvert \
lcov \
libblas-dev \
libboost-dev \
libboost-filesystem-dev \
libboost-mpi-dev \
libboost-serialization-dev \
libboost-test-dev \
libdigest-sha-perl \
libfftw3-dev \
libfftw3-mpi-dev \
libgsl-dev \
libhdf5-openmpi-dev \
liblapack-dev \
libopenmpi-dev \
libthrust-dev \
libtool \
nvidia-cuda-toolkit \
openmpi-bin \
openssh-client \
perl \
pkg-config \
pre-commit \
python3 \
python3-dev \
pylint \
python3-coverage \
python3-dev \
python3-h5py \
python3-ipykernel \
python3-jinja2 \
python3-lxml \
python3-matplotlib \
python3-nbconvert \
python3-numpy \
python3-numpydoc \
python3-pint \
python3-pip \
python3-packaging \
python3-requests \
python3-scipy \
python3-setuptools \
python3-sympy \
python3-sphinx \
python3-sphinxcontrib.bibtex \
python3-tqdm \
python3-venv \
python3-vtk9 \
rsync \
texlive-base \
vim && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

COPY install-pfft.sh /tmp
COPY install-scafacos.sh /tmp
COPY install-kokkos.sh /tmp

RUN sh /tmp/install-pfft.sh && rm /tmp/install-pfft.sh && \
sh /tmp/install-scafacos.sh && rm /tmp/install-scafacos.sh && \
sh /tmp/install-kokkos.sh && rm /tmp/install-kokkos.sh && \
ldconfig

ENV NVIDIA_VISIBLE_DEVICES all
ENV NVIDIA_DRIVER_CAPABILITIES compute,utility
ENV JUPYTER_PLATFORM_DIRS 1

COPY --chown=1000:1000 jupyter_nbconvert_config.json /tmp

RUN userdel ubuntu && rm -rf /home/ubuntu && useradd -u 1000 -m espresso
ENV HOME="/home/espresso"
RUN echo | cpan && \
echo | cpan JSON::XS && \
chown -R espresso:espresso /home/espresso/.cpan/
USER espresso
ENV VIRTUAL_ENV "$HOME/venv"
ENV PATH "$HOME/.local/bin:$VIRTUAL_ENV/bin:$PATH"
RUN cd "${HOME}" && \
python3 -m venv --system-site-packages venv && \
. venv/bin/activate && \
python3 -m pip install --no-cache \
jupyterlab==4.0.13 \
pep8==1.7.1 \
autopep8==2.1.0 \
pycodestyle==2.11.1 \
sphinx-toggleprompt==0.5.2 && \
jupyter_config_root=$(jupyter --paths --json | jq ".config[0]") && \
jupyter_config_root=${jupyter_config_root#\"} && \
jupyter_config_root=${jupyter_config_root%\"} && \
jupyter_kernels_root=$(jupyter --paths --json | jq ".data[0]")/kernels && \
jupyter_kernels_root=${jupyter_kernels_root#\"} && \
jupyter_kernels_root=${jupyter_kernels_root%\"} && \
mkdir -p "${jupyter_config_root}" "${jupyter_kernels_root}" && \
mv "/tmp/jupyter_nbconvert_config.json" "${jupyter_config_root}/" && \
ln -s "${VIRTUAL_ENV}/share/jupyter/kernels/python3" "${jupyter_kernels_root}/python3" && \
deactivate && \
mkdir -p "${HOME}/.local/bin" && \
mkdir -p "${HOME}/.local/etc/alternatives" && \
mkdir -p "${HOME}/.local/var/lib/alternatives"
WORKDIR /home/espresso
84 changes: 0 additions & 84 deletions docker/Dockerfile-ubuntu-22.04

This file was deleted.

11 changes: 8 additions & 3 deletions docker/Dockerfile-ubuntu-wo-dependencies
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:jammy AS image_base
FROM ubuntu:noble AS image_base
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y \
apt-utils \
Expand All @@ -7,10 +7,14 @@ RUN apt-get update && \
ccache \
cmake \
cython3 \
gcc-11 g++-11 \
gcc-13 g++-13 \
gdb \
git \
libboost-dev libboost-serialization-dev libboost-mpi-dev libboost-filesystem-dev libboost-test-dev \
libboost-dev \
libboost-filesystem-dev \
libboost-mpi-dev \
libboost-serialization-dev \
libboost-test-dev \
libopenmpi-dev \
openssh-client \
openmpi-bin \
Expand All @@ -19,6 +23,7 @@ RUN apt-get update && \
python3-h5py \
python3-lxml \
python3-numpy \
python3-packaging \
python3-pip \
python3-scipy \
python3-setuptools \
Expand Down
15 changes: 15 additions & 0 deletions docker/install-kokkos.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/bin/sh

set -e

cd /tmp

git clone -b 4.3.00 https://github.com/kokkos/kokkos
cd kokkos/
mkdir build
cd build/
cmake .. -D Kokkos_ENABLE_CUDA=OFF -DKokkos_ENABLE_OPENMP=ON
make -j $(nproc) install
cd
reinaual marked this conversation as resolved.
Show resolved Hide resolved
rm -r /tmp/kokkos
ldconfig
2 changes: 1 addition & 1 deletion docker/install-pfft.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh

set -e

Expand Down
2 changes: 1 addition & 1 deletion docker/install-scafacos.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/bash
#!/bin/sh

set -e

Expand Down
7 changes: 7 additions & 0 deletions docker/jupyter_nbconvert_config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"version": 1,
"Exporter": {
"require_js_url": "https://cdnjs.cloudflare.com/ajax/libs/require.js/2.1.10/require.min.js",
"mathjax_url": "https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.7/latest.js?config=TeX-AMS_CHTML-full,Safe"
}
}