diff --git a/tools/dashboard/dashboard.conf b/tools/dashboard/dashboard.conf index e4c3e350bf..5f092e02aa 100644 --- a/tools/dashboard/dashboard.conf +++ b/tools/dashboard/dashboard.conf @@ -309,6 +309,34 @@ timeout: 170 host: GCP report_url: https://storage.googleapis.com/cp2k-ci/dashboard_spack-psmp-4x2_report.txt +[spack-psmp-gcc10] +sortkey: 1045 +name: Spack (psmp, GCC 10) +timeout: 170 +host: GCP +report_url: https://storage.googleapis.com/cp2k-ci/dashboard_spack-psmp-gcc10_report.txt + +[spack-psmp-gcc11] +sortkey: 1046 +name: Spack (psmp, GCC 11) +timeout: 170 +host: GCP +report_url: https://storage.googleapis.com/cp2k-ci/dashboard_spack-psmp-gcc11_report.txt + +[spack-psmp-gcc12] +sortkey: 1047 +name: Spack (psmp, GCC 12) +timeout: 170 +host: GCP +report_url: https://storage.googleapis.com/cp2k-ci/dashboard_spack-psmp-gcc12_report.txt + +[spack-psmp-gcc14] +sortkey: 1049 +name: Spack (psmp, GCC 14) +timeout: 170 +host: GCP +report_url: https://storage.googleapis.com/cp2k-ci/dashboard_spack-psmp-gcc14_report.txt + # ============================================================================== [asan-psmp] diff --git a/tools/docker/Dockerfile.test_spack_psmp-gcc11 b/tools/docker/Dockerfile.test_spack_psmp-gcc11 new file mode 100644 index 0000000000..4060176c83 --- /dev/null +++ b/tools/docker/Dockerfile.test_spack_psmp-gcc11 @@ -0,0 +1,97 @@ +# +# This file was created by generate_dockerfiles.py. +# Usage: ./spack_cache_start.sh; podman build --network=host --shm-size=1g -f ./Dockerfile.test_spack_psmp-gcc11 ../../ +# + +ARG BASE_IMAGE="ubuntu:24.04" + +###### Stage 1: Build CP2K ###### + +FROM "${BASE_IMAGE}" AS build_cp2k + +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + bzip2 \ + ca-certificates \ + cmake \ + g++-11 \ + gcc-11 \ + gfortran-11 \ + git \ + gnupg \ + libssh-dev \ + libssl-dev \ + libtool \ + libtool-bin \ + lsb-release \ + make \ + ninja-build \ + patch \ + pkgconf \ + python3 \ + python3-dev \ + python3-pip \ + python3-venv \ + unzip \ + wget \ + xxd \ + xz-utils \ + zstd \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-11 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-11 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-11 /usr/local/bin/gfortran + +ARG SPACK_CACHE="s3://spack-cache --s3-endpoint-url=http://localhost:9000" + +# Copy CP2K repository into container +WORKDIR /opt +COPY . cp2k/ + +# Build CP2K dependencies +WORKDIR /opt/cp2k +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -bd_only -cv psmp -mpi mpich" + +# Build and install CP2K +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -cv psmp -mpi mpich" + +###### Stage 2: Install CP2K ###### + +FROM "${BASE_IMAGE}" AS install_cp2k + +# Install required packages +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + g++-11 \ + gcc-11 \ + gfortran-11 \ + python3 \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-11 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-11 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-11 /usr/local/bin/gfortran + +WORKDIR /opt/cp2k + +# Install CP2K dependencies built with spack +COPY --from=build_cp2k /opt/cp2k/spack/spack-1.1.0/opt/spack ./spack/spack-1.1.0/opt/spack + +# Install CP2K +COPY --from=build_cp2k /opt/cp2k/install ./install + +# Install CP2K regression tests +COPY --from=build_cp2k /opt/cp2k/tests ./tests +COPY --from=build_cp2k /opt/cp2k/src/grid/sample_tasks ./src/grid/sample_tasks + +# Install CP2K/Quickstep CI benchmarks +COPY --from=build_cp2k /opt/cp2k/benchmarks/CI ./benchmarks/CI + +# Run CP2K regression test +RUN /bin/bash -o pipefail -c "/opt/cp2k/install/bin/entrypoint.sh /opt/cp2k/install/bin/run_tests " + +# Create entrypoint and finalise container build +WORKDIR /mnt +ENTRYPOINT ["/opt/cp2k/install/bin/entrypoint.sh"] +CMD ["cp2k", "--help"] diff --git a/tools/docker/Dockerfile.test_spack_psmp-gcc12 b/tools/docker/Dockerfile.test_spack_psmp-gcc12 new file mode 100644 index 0000000000..49894e286a --- /dev/null +++ b/tools/docker/Dockerfile.test_spack_psmp-gcc12 @@ -0,0 +1,97 @@ +# +# This file was created by generate_dockerfiles.py. +# Usage: ./spack_cache_start.sh; podman build --network=host --shm-size=1g -f ./Dockerfile.test_spack_psmp-gcc12 ../../ +# + +ARG BASE_IMAGE="ubuntu:24.04" + +###### Stage 1: Build CP2K ###### + +FROM "${BASE_IMAGE}" AS build_cp2k + +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + bzip2 \ + ca-certificates \ + cmake \ + g++-12 \ + gcc-12 \ + gfortran-12 \ + git \ + gnupg \ + libssh-dev \ + libssl-dev \ + libtool \ + libtool-bin \ + lsb-release \ + make \ + ninja-build \ + patch \ + pkgconf \ + python3 \ + python3-dev \ + python3-pip \ + python3-venv \ + unzip \ + wget \ + xxd \ + xz-utils \ + zstd \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-12 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-12 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-12 /usr/local/bin/gfortran + +ARG SPACK_CACHE="s3://spack-cache --s3-endpoint-url=http://localhost:9000" + +# Copy CP2K repository into container +WORKDIR /opt +COPY . cp2k/ + +# Build CP2K dependencies +WORKDIR /opt/cp2k +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -bd_only -cv psmp -mpi mpich" + +# Build and install CP2K +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -cv psmp -mpi mpich" + +###### Stage 2: Install CP2K ###### + +FROM "${BASE_IMAGE}" AS install_cp2k + +# Install required packages +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + g++-12 \ + gcc-12 \ + gfortran-12 \ + python3 \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-12 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-12 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-12 /usr/local/bin/gfortran + +WORKDIR /opt/cp2k + +# Install CP2K dependencies built with spack +COPY --from=build_cp2k /opt/cp2k/spack/spack-1.1.0/opt/spack ./spack/spack-1.1.0/opt/spack + +# Install CP2K +COPY --from=build_cp2k /opt/cp2k/install ./install + +# Install CP2K regression tests +COPY --from=build_cp2k /opt/cp2k/tests ./tests +COPY --from=build_cp2k /opt/cp2k/src/grid/sample_tasks ./src/grid/sample_tasks + +# Install CP2K/Quickstep CI benchmarks +COPY --from=build_cp2k /opt/cp2k/benchmarks/CI ./benchmarks/CI + +# Run CP2K regression test +RUN /bin/bash -o pipefail -c "/opt/cp2k/install/bin/entrypoint.sh /opt/cp2k/install/bin/run_tests " + +# Create entrypoint and finalise container build +WORKDIR /mnt +ENTRYPOINT ["/opt/cp2k/install/bin/entrypoint.sh"] +CMD ["cp2k", "--help"] diff --git a/tools/docker/Dockerfile.test_spack_psmp-gcc14 b/tools/docker/Dockerfile.test_spack_psmp-gcc14 new file mode 100644 index 0000000000..fd0596a4e9 --- /dev/null +++ b/tools/docker/Dockerfile.test_spack_psmp-gcc14 @@ -0,0 +1,97 @@ +# +# This file was created by generate_dockerfiles.py. +# Usage: ./spack_cache_start.sh; podman build --network=host --shm-size=1g -f ./Dockerfile.test_spack_psmp-gcc14 ../../ +# + +ARG BASE_IMAGE="ubuntu:24.04" + +###### Stage 1: Build CP2K ###### + +FROM "${BASE_IMAGE}" AS build_cp2k + +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + bzip2 \ + ca-certificates \ + cmake \ + g++-14 \ + gcc-14 \ + gfortran-14 \ + git \ + gnupg \ + libssh-dev \ + libssl-dev \ + libtool \ + libtool-bin \ + lsb-release \ + make \ + ninja-build \ + patch \ + pkgconf \ + python3 \ + python3-dev \ + python3-pip \ + python3-venv \ + unzip \ + wget \ + xxd \ + xz-utils \ + zstd \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-14 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-14 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-14 /usr/local/bin/gfortran + +ARG SPACK_CACHE="s3://spack-cache --s3-endpoint-url=http://localhost:9000" + +# Copy CP2K repository into container +WORKDIR /opt +COPY . cp2k/ + +# Build CP2K dependencies +WORKDIR /opt/cp2k +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -bd_only -cv psmp -mpi mpich" + +# Build and install CP2K +RUN /bin/bash -o pipefail -c "source ./make_cp2k.sh -cv psmp -mpi mpich" + +###### Stage 2: Install CP2K ###### + +FROM "${BASE_IMAGE}" AS install_cp2k + +# Install required packages +RUN apt-get update -qq && apt-get install -qq --no-install-recommends \ + g++-14 \ + gcc-14 \ + gfortran-14 \ + python3 \ + && rm -rf /var/lib/apt/lists/* + +# Create links in /usr/local/bin to override tbe links in /usr/bin +RUN ln -sf /usr/bin/gcc-14 /usr/local/bin/gcc && \ + ln -sf /usr/bin/g++-14 /usr/local/bin/g++ && \ + ln -sf /usr/bin/gfortran-14 /usr/local/bin/gfortran + +WORKDIR /opt/cp2k + +# Install CP2K dependencies built with spack +COPY --from=build_cp2k /opt/cp2k/spack/spack-1.1.0/opt/spack ./spack/spack-1.1.0/opt/spack + +# Install CP2K +COPY --from=build_cp2k /opt/cp2k/install ./install + +# Install CP2K regression tests +COPY --from=build_cp2k /opt/cp2k/tests ./tests +COPY --from=build_cp2k /opt/cp2k/src/grid/sample_tasks ./src/grid/sample_tasks + +# Install CP2K/Quickstep CI benchmarks +COPY --from=build_cp2k /opt/cp2k/benchmarks/CI ./benchmarks/CI + +# Run CP2K regression test +RUN /bin/bash -o pipefail -c "/opt/cp2k/install/bin/entrypoint.sh /opt/cp2k/install/bin/run_tests " + +# Create entrypoint and finalise container build +WORKDIR /mnt +ENTRYPOINT ["/opt/cp2k/install/bin/entrypoint.sh"] +CMD ["cp2k", "--help"] diff --git a/tools/docker/cp2k-ci.conf b/tools/docker/cp2k-ci.conf index 07a053582b..73b782ef2d 100644 --- a/tools/docker/cp2k-ci.conf +++ b/tools/docker/cp2k-ci.conf @@ -366,6 +366,38 @@ nodepools: pool-main build_path: / dockerfile: /tools/docker/Dockerfile.test_spack_psmp-4x2 +[spack-psmp-gcc10] +display_name: Spack (psmp, GCC 10) +tags: weekly-afternoon +cpu: 32 +nodepools: pool-main +build_path: / +dockerfile: /tools/docker/Dockerfile.test_spack_psmp-gcc10 + +[spack-psmp-gcc11] +display_name: Spack (psmp, GCC 11) +tags: weekly-afternoon +cpu: 32 +nodepools: pool-main +build_path: / +dockerfile: /tools/docker/Dockerfile.test_spack_psmp-gcc11 + +[spack-psmp-gcc12] +display_name: Spack (psmp, GCC 12) +tags: weekly-afternoon +cpu: 32 +nodepools: pool-main +build_path: / +dockerfile: /tools/docker/Dockerfile.test_spack_psmp-gcc12 + +[spack-psmp-gcc14] +display_name: Spack (psmp, GCC 14) +tags: weekly-afternoon +cpu: 32 +nodepools: pool-main +build_path: / +dockerfile: /tools/docker/Dockerfile.test_spack_psmp-gcc14 + [asan-psmp] display_name: Address Sanitizer tags: weekly-afternoon @@ -375,4 +407,4 @@ cache_from: pdbg build_path: / dockerfile: /tools/docker/Dockerfile.test_asan-psmp -#EOF +# EOF diff --git a/tools/docker/generate_dockerfiles.py b/tools/docker/generate_dockerfiles.py index d18561beec..c770f842ff 100755 --- a/tools/docker/generate_dockerfiles.py +++ b/tools/docker/generate_dockerfiles.py @@ -57,8 +57,13 @@ def main() -> None: with OutputFile(f"Dockerfile.test_spack_psmp", args.check) as f: f.write(install_cp2k_spack("psmp", mpi_mode="mpich")) - with OutputFile(f"Dockerfile.test_spack_psmp-gcc10", args.check) as f: - f.write(install_cp2k_spack("psmp", mpi_mode="mpich", gcc_version=10)) + for gcc_version in 10, 11, 12, 14: + with OutputFile( + f"Dockerfile.test_spack_psmp-gcc{gcc_version}", args.check + ) as f: + f.write( + install_cp2k_spack("psmp", mpi_mode="mpich", gcc_version=gcc_version) + ) with OutputFile(f"Dockerfile.test_spack_psmp-4x2", args.check) as f: testopts = f"--mpiranks=4 --ompthreads=2"