From 06a09eee0d81807e35756313a6568850d9298aaf Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 12 Mar 2026 14:56:57 -0600 Subject: [PATCH 1/4] A batch of changes from containers and ec2 --- configs/sites/tier1/container/packages.yaml | 37 +++++++-- .../tier1/container/packages_oneapi.yaml | 4 +- .../sites/tier2/aws-ubuntu2404/packages.yaml | 83 ++++++++++++------- 3 files changed, 84 insertions(+), 40 deletions(-) diff --git a/configs/sites/tier1/container/packages.yaml b/configs/sites/tier1/container/packages.yaml index af5a307f5..e5d79f6a2 100644 --- a/configs/sites/tier1/container/packages.yaml +++ b/configs/sites/tier1/container/packages.yaml @@ -1,8 +1,36 @@ packages: all: - target: [core2] + target: [x86_64_v3] + awscli-v2: + require: + - "@2.22.4" + cairo: + variants: +pic + ewok-env: + require: + - +ecflow + fontconfig: + variants: +pic met: variants: +python +grib2 +graphics +lidar2nc +modis + parallelio: + require: + - +pnetcdf + pixman: + variants: +pic + py-awscrt: + require: + - "@0.19.19" + py-botocore: + require: + - "@1.34.162" + py-boto3: + require: + - "@1.34.162" + py-netcdf4: + require: + - "@1.7.2" + # System packages installed during the container build. grep: externals: @@ -46,13 +74,8 @@ packages: - spec: qt@5.15.3 prefix: /usr version: [5.15.3] - wget: - buildable: false - externals: - - spec: wget@1.21.4 - prefix: /usr perl: buildable: false externals: - spec: perl@5.38.2 - prefix: /usr \ No newline at end of file + prefix: /usr diff --git a/configs/sites/tier1/container/packages_oneapi.yaml b/configs/sites/tier1/container/packages_oneapi.yaml index 44c1482c9..0ab8599b1 100644 --- a/configs/sites/tier1/container/packages_oneapi.yaml +++ b/configs/sites/tier1/container/packages_oneapi.yaml @@ -15,8 +15,8 @@ packages: modules: - umf/1.0.2 - tbb/2022.3 - - compiler-rt/2025.3.0 - - compiler/2025.3.0 + - compiler-rt/2025.3.2 + - compiler/2025.3.2 extra_attributes: compilers: c: /opt/intel/oneapi/compiler/2025.3/bin/icx diff --git a/configs/sites/tier2/aws-ubuntu2404/packages.yaml b/configs/sites/tier2/aws-ubuntu2404/packages.yaml index 3b8a5ec72..2d4232854 100644 --- a/configs/sites/tier2/aws-ubuntu2404/packages.yaml +++ b/configs/sites/tier2/aws-ubuntu2404/packages.yaml @@ -1,66 +1,87 @@ packages: - gmake: - buildable: false + # Package constraints. + awscli-v2: + require: + - "@2.22.4" + ewok-env: + require: + - +ecflow + py-awscrt: + require: + - "@0.19.19" + py-botocore: + require: + - "@1.34.162" + py-boto3: + require: + - "@1.34.162" + py-netcdf4: + require: + - "@1.7.2" + + # System packages. + autoconf: externals: - - spec: gmake@4.3 + - spec: autoconf@2.71 prefix: /usr - grep: + automake: externals: - - spec: grep@3.11 + - spec: automake@1.16.5 prefix: /usr - wget: + coreutils: externals: - - spec: wget@1.21.4 + - spec: coreutils@9.4 prefix: /usr - perl: + diffutils: externals: - - spec: perl@5.38.2~cpanm+opcode+open+shared+threads + - spec: diffutils@3.10 prefix: /usr findutils: externals: - spec: findutils@4.9.0 prefix: /usr - coreutils: + flex: externals: - - spec: coreutils@9.4 + - spec: flex@2.6.4+lex prefix: /usr - pkgconf: + gawk: externals: - - spec: pkgconf@1.8.1 + - spec: gawk@5.2.1 prefix: /usr - libtool: + git: externals: - - spec: libtool@2.4.7 + - spec: git@2.43.0~tcltk prefix: /usr - autoconf: + gmake: + buildable: false externals: - - spec: autoconf@2.71 + - spec: gmake@4.3 prefix: /usr - automake: + grep: externals: - - spec: automake@1.16.5 + - spec: grep@3.11 prefix: /usr - gawk: + groff: externals: - - spec: gawk@5.2.1 + - spec: groff@1.23.0 prefix: /usr - git: + libtool: externals: - - spec: git@2.43.0~tcltk + - spec: libtool@2.4.7 prefix: /usr - flex: + perl: externals: - - spec: flex@2.6.4+lex + - spec: perl@5.38.2~cpanm+opcode+open+shared+threads prefix: /usr - sed: + pkgconf: externals: - - spec: sed@4.9 + - spec: pkgconf@1.8.1 prefix: /usr - diffutils: + sed: externals: - - spec: diffutils@3.10 + - spec: sed@4.9 prefix: /usr - groff: + wget: externals: - - spec: groff@1.23.0 + - spec: wget@1.21.4 prefix: /usr From b3be5eaab8b3a2f09e060b73933b70341ecb2ad6 Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 12 Mar 2026 15:04:55 -0600 Subject: [PATCH 2/4] Docker fixes --- .dockerignore | 19 ++++++++++ configs/sites/tier1/container/Dockerfile.gcc | 35 ++++++++++++++++--- .../sites/tier1/container/Dockerfile.oneapi | 35 ++++++++++++++++--- 3 files changed, 79 insertions(+), 10 deletions(-) create mode 100644 .dockerignore diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 000000000..571aa0783 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,19 @@ +# .dockerignore + +# Log files. +log.* +*.log + +# spack-stack environments and builds. +envs/ +.env/ +build/ +cache/ + +# Misc. +.vscode +.Trashes +.github/ +venv/ +.venv/ + diff --git a/configs/sites/tier1/container/Dockerfile.gcc b/configs/sites/tier1/container/Dockerfile.gcc index 917527d7c..ef9a6bbeb 100644 --- a/configs/sites/tier1/container/Dockerfile.gcc +++ b/configs/sites/tier1/container/Dockerfile.gcc @@ -72,10 +72,15 @@ FROM ubuntu_base AS builder ENV SPACK_STACK_DIR=/opt/spack-stack \ SPACK_ROOT=/opt/spack-stack/spack - # Copy spack-stack from build context. Note the build context must be the # root of the spack-stack repository (see the README.md for details). -COPY . ${SPACK_STACK_DIR} +# Do not copy the dockerfiles into the container. +COPY --exclude=configs/sites/tier1/container/Dockerfile.oneapi \ + --exclude=configs/sites/tier1/container/Dockerfile.gcc \ + --exclude=configs/sites/tier1/container/packages_oneapi.yaml \ + --exclude=envs/** \ + --exclude=cache/** \ + . ${SPACK_STACK_DIR} # Create spack-stack environment WORKDIR /opt/spack-stack @@ -89,12 +94,19 @@ RUN mkdir -p /tmp/spack-stack && \ --compiler $COMPILER && \ cd ${SPACK_STACK_DIR}/envs/container && \ spack env activate . && \ - spack concretize 2>&1 | tee log.concretize && \ - spack install --fail-fast -j ${BUILD_JOBS} 2>&1 | tee log.install && \ + spack concretize 2>&1 | tee log.concretize + +# Build the spack environment. +RUN source setup.sh && cd ${SPACK_STACK_DIR}/envs/container && spack env activate . && \ + spack install --fail-fast -j ${BUILD_JOBS} 2>&1 | tee log.install + +# Setup modules and meta-modules. +RUN source setup.sh && cd ${SPACK_STACK_DIR}/envs/container && spack env activate . && \ spack module tcl refresh -y && \ spack stack setup-meta-modules && \ # Save output of spack find. spack find 2>&1 | tee /opt/spack-software/spack_find.out && \ + cp ./log.concretize /opt/spack-software/log.concretize && \ spack clean --all ## ---------- Create runtime container ---------- @@ -118,7 +130,20 @@ RUN echo "ulimit -s unlimited" > /etc/spack_container_rc.sh \ && echo "export PRTE_MCA_rmaps_default_mapping_policy=:oversubscribe" >> /etc/spack_container_rc.sh \ && echo "# TCL module path for the spack-stack environment." >> /etc/spack_container_rc.sh \ && echo "source /etc/profile.d/modules.sh" >> /etc/spack_container_rc.sh \ - && echo "module use /opt/spack-software/modules/Core" >> /etc/spack_container_rc.sh \ + && echo "module use /opt/spack-software/modulefiles" >> /etc/spack_container_rc.sh \ + && echo "module use /opt/spack-software/modulefiles/Core" >> /etc/spack_container_rc.sh \ + && echo "# Bash function to load modules necessary to build the JEDI bundle." >> /etc/spack_container_rc.sh \ + && echo "load_jedi_bundle_env() {" >> /etc/spack_container_rc.sh \ + && echo " module purge" >> /etc/spack_container_rc.sh \ + && echo " module load stack-gcc" >> /etc/spack_container_rc.sh \ + && echo " module load stack-openmpi" >> /etc/spack_container_rc.sh \ + && echo " module load base-env" >> /etc/spack_container_rc.sh \ + && echo " module load jedi-mpas-env" >> /etc/spack_container_rc.sh \ + && echo " module load py-fortranformat" >> /etc/spack_container_rc.sh \ + && echo " module load jedi-fv3-env" >> /etc/spack_container_rc.sh \ + && echo " module load ewok-env" >> /etc/spack_container_rc.sh \ + && echo " module load ip" >> /etc/spack_container_rc.sh \ + && echo "}" >> /etc/spack_container_rc.sh \ \ && echo "source /etc/spack_container_rc.sh" >> /etc/bash.bashrc \ && printf "[credential]\n helper = cache --timeout=7200\n" >> /root/.gitconfig \ && mkdir /root/.pmix \ diff --git a/configs/sites/tier1/container/Dockerfile.oneapi b/configs/sites/tier1/container/Dockerfile.oneapi index c22058808..a43b5220d 100644 --- a/configs/sites/tier1/container/Dockerfile.oneapi +++ b/configs/sites/tier1/container/Dockerfile.oneapi @@ -91,7 +91,13 @@ ENV SPACK_STACK_DIR=/opt/spack-stack \ # Copy spack-stack from build context. Note the build context must be the # root of the spack-stack repository (see the README.md for details). -COPY . ${SPACK_STACK_DIR} +# Do not copy the dockerfiles into the container. +COPY --exclude=configs/sites/tier1/container/Dockerfile.oneapi \ + --exclude=configs/sites/tier1/container/Dockerfile.gcc \ + --exclude=configs/sites/tier1/container/packages_gcc.yaml \ + --exclude=envs/** \ + --exclude=cache/** \ + . ${SPACK_STACK_DIR} # Create spack-stack environment WORKDIR /opt/spack-stack @@ -105,12 +111,19 @@ RUN mkdir -p /tmp/spack-stack && \ --compiler oneapi && \ cd ${SPACK_STACK_DIR}/envs/container && \ spack env activate . && \ - spack concretize 2>&1 | tee log.concretize && \ - spack install --fail-fast -j ${BUILD_JOBS} 2>&1 | tee log.install && \ + spack concretize 2>&1 | tee log.concretize + +# Build the spack environment. +RUN source setup.sh && cd ${SPACK_STACK_DIR}/envs/container && spack env activate . && \ + spack install --fail-fast -j ${BUILD_JOBS} 2>&1 | tee log.install + +# Setup modules and meta-modules. +RUN source setup.sh && cd ${SPACK_STACK_DIR}/envs/container && spack env activate . && \ spack module tcl refresh -y && \ spack stack setup-meta-modules && \ # Save output of spack find. spack find 2>&1 | tee /opt/spack-software/spack_find.out && \ + cp ./log.concretize /opt/spack-software/log.concretize && \ spack clean --all ## ---------- Create runtime container ---------- @@ -129,10 +142,22 @@ RUN echo "ulimit -s unlimited" > /etc/spack_container_rc.sh \ && echo "export CXX=icpx" >> /etc/spack_container_rc.sh \ && echo "export FC=ifx" >> /etc/spack_container_rc.sh \ && echo "# TCL module path for the spack-stack environment." >> /etc/spack_container_rc.sh \ - && echo "export MODULEPATH=/opt/spack-software/modules/Core" >> /etc/spack_container_rc.sh \ && echo "source /etc/profile.d/modules.sh" >> /etc/spack_container_rc.sh \ && echo "module use /opt/intel/oneapi/modulefiles" >> /etc/spack_container_rc.sh \ - && echo "module use /opt/spack-software/modules/Core" >> /etc/spack_container_rc.sh \ + && echo "module use /opt/spack-software/modulefiles" >> /etc/spack_container_rc.sh \ + && echo "module use /opt/spack-software/modulefiles/Core" >> /etc/spack_container_rc.sh \ + && echo "# Bash function to load modules necessary to build the JEDI bundle." >> /etc/spack_container_rc.sh \ + && echo "load_jedi_bundle_env() {" >> /etc/spack_container_rc.sh \ + && echo " module purge" >> /etc/spack_container_rc.sh \ + && echo " module load stack-intel-oneapi-compilers" >> /etc/spack_container_rc.sh \ + && echo " module load stack-intel-oneapi-mpi" >> /etc/spack_container_rc.sh \ + && echo " module load base-env" >> /etc/spack_container_rc.sh \ + && echo " module load jedi-mpas-env" >> /etc/spack_container_rc.sh \ + && echo " module load py-fortranformat" >> /etc/spack_container_rc.sh \ + && echo " module load jedi-fv3-env" >> /etc/spack_container_rc.sh \ + && echo " module load ewok-env" >> /etc/spack_container_rc.sh \ + && echo " module load ip" >> /etc/spack_container_rc.sh \ + && echo "}" >> /etc/spack_container_rc.sh \ \ && echo "source /etc/spack_container_rc.sh" >> /etc/bash.bashrc \ && printf "[credential]\n helper = cache --timeout=7200\n" >> /root/.gitconfig \ && mkdir /root/.pmix From 1f8734ed9d5ea57fe9cbd1b3404e0c49a17d632f Mon Sep 17 00:00:00 2001 From: Evan Parker Date: Fri, 13 Mar 2026 15:55:42 +0000 Subject: [PATCH 3/4] Remove qt and alphabetize --- configs/sites/tier1/container/Dockerfile.gcc | 4 --- .../sites/tier1/container/Dockerfile.oneapi | 4 --- configs/sites/tier1/container/packages.yaml | 26 +++++++------------ 3 files changed, 10 insertions(+), 24 deletions(-) diff --git a/configs/sites/tier1/container/Dockerfile.gcc b/configs/sites/tier1/container/Dockerfile.gcc index ef9a6bbeb..22da60357 100644 --- a/configs/sites/tier1/container/Dockerfile.gcc +++ b/configs/sites/tier1/container/Dockerfile.gcc @@ -34,10 +34,6 @@ RUN set -euo pipefail; \ # External dependencies. libcurl4-openssl-dev \ libmysqlclient-dev \ - libqt5svg5-dev \ - qt5-qmake \ - qt5dxcb-plugin \ - qtbase5-dev \ zstd \ # Shell tools, source retrieval and networking. sed \ diff --git a/configs/sites/tier1/container/Dockerfile.oneapi b/configs/sites/tier1/container/Dockerfile.oneapi index a43b5220d..f0fe200b8 100644 --- a/configs/sites/tier1/container/Dockerfile.oneapi +++ b/configs/sites/tier1/container/Dockerfile.oneapi @@ -34,10 +34,6 @@ RUN set -euo pipefail; \ # External dependencies. libcurl4-openssl-dev \ libmysqlclient-dev \ - libqt5svg5-dev \ - qt5-qmake \ - qt5dxcb-plugin \ - qtbase5-dev \ zstd \ # Shell tools, source retrieval and networking. sed \ diff --git a/configs/sites/tier1/container/packages.yaml b/configs/sites/tier1/container/packages.yaml index e5d79f6a2..67b50165a 100644 --- a/configs/sites/tier1/container/packages.yaml +++ b/configs/sites/tier1/container/packages.yaml @@ -32,27 +32,23 @@ packages: - "@1.7.2" # System packages installed during the container build. - grep: - externals: - - spec: grep@3.11 - prefix: /usr - findutils: + autoconf: externals: - - spec: findutils@4.9.0 + - spec: autoconf@2.71 prefix: /usr coreutils: externals: - spec: coreutils@9.4 prefix: /usr - autoconf: - externals: - - spec: autoconf@2.71 - prefix: /usr diffutils: buildable: false externals: - spec: diffutils@3.10 prefix: /usr + findutils: + externals: + - spec: findutils@4.9.0 + prefix: /usr git: buildable: false externals: @@ -63,17 +59,15 @@ packages: externals: - spec: git-lfs@3.4.1 prefix: /usr - llvm: - buildable: false + grep: externals: - - spec: llvm@14.0.6 + - spec: grep@3.11 prefix: /usr - qt: + llvm: buildable: false externals: - - spec: qt@5.15.3 + - spec: llvm@14.0.6 prefix: /usr - version: [5.15.3] perl: buildable: false externals: From 272b880d9098d117d613e8d849833eedb93ca07b Mon Sep 17 00:00:00 2001 From: Evan Parker Date: Fri, 13 Mar 2026 16:13:02 +0000 Subject: [PATCH 4/4] notest fix ec2 packages from merge --- .../sites/tier2/aws-ubuntu2404/packages.yaml | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/configs/sites/tier2/aws-ubuntu2404/packages.yaml b/configs/sites/tier2/aws-ubuntu2404/packages.yaml index 2d4232854..2541a5ab4 100644 --- a/configs/sites/tier2/aws-ubuntu2404/packages.yaml +++ b/configs/sites/tier2/aws-ubuntu2404/packages.yaml @@ -28,6 +28,10 @@ packages: externals: - spec: automake@1.16.5 prefix: /usr + binutils: + externals: + - spec: binutils@2.42+gold~headers + prefix: /usr coreutils: externals: - spec: coreutils@9.4 @@ -52,6 +56,10 @@ packages: externals: - spec: git@2.43.0~tcltk prefix: /usr + git-lfs: + externals: + - spec: git-lfs@3.4.1 + prefix: /usr gmake: buildable: false externals: @@ -69,6 +77,10 @@ packages: externals: - spec: libtool@2.4.7 prefix: /usr + m4: + externals: + - spec: m4@1.4.19 + prefix: /usr perl: externals: - spec: perl@5.38.2~cpanm+opcode+open+shared+threads @@ -81,7 +93,6 @@ packages: externals: - spec: sed@4.9 prefix: /usr - wget: + tar: externals: - - spec: wget@1.21.4 - prefix: /usr + - spec: tar@1.35