From aa7829627f884e7d9af9e879f651386b594e3a7b Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 13:01:45 -0600 Subject: [PATCH 01/11] Use oraclelinux instead of centos. --- base/centos8/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index e203960..5a168c4 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -4,8 +4,8 @@ # A base CentOS8 install + MPI, HDF5, NetCDF and PNetCDF, as well as other core packages for escomp containers # ################################################################################################################ -# Use latest CentOS8: -FROM centos:8 +# Use latest CentOS8 clone hosted by Oracle: +FROM oraclelinux:8 # First, we upate the default packages and install some other necessary ones - while this may give # some people updated versions of packages vs. others, these differences should not be numerically From ca2f57cbe709e115b9d4eb9a466b80ab291f36d3 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:23:55 -0600 Subject: [PATCH 02/11] Switch to oraclelinux 9. --- base/centos8/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index 5a168c4..7677cec 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -5,7 +5,7 @@ ################################################################################################################ # Use latest CentOS8 clone hosted by Oracle: -FROM oraclelinux:8 +FROM oraclelinux:9 # First, we upate the default packages and install some other necessary ones - while this may give # some people updated versions of packages vs. others, these differences should not be numerically From 638e802c96e4bc116c515a7fe50d6e554c2990d4 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:24:08 -0600 Subject: [PATCH 03/11] Explicitly request pip. --- base/centos8/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index 7677cec..b8edb32 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -14,7 +14,7 @@ FROM oraclelinux:9 RUN yum -y update && \ yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && \ yum -y install vim emacs-nox git subversion which sudo csh make m4 cmake wget file byacc curl-devel zlib-devel && \ - yum -y install perl-XML-LibXML gcc-gfortran gcc-c++ dnf-plugins-core python3 perl-core && \ + yum -y install perl-XML-LibXML gcc-gfortran gcc-c++ dnf-plugins-core python3 pip perl-core && \ yum -y install ftp xmlstarlet diffutils && \ yum -y install git-lfs latexmk texlive-amscls texlive-anyfontsize texlive-cmap texlive-fancyhdr texlive-fncychap \ texlive-dvisvgm texlive-metafont texlive-ec texlive-titlesec texlive-babel-english texlive-tabulary \ From ddfe1ce1e3e0f5ef02b6545e782c2219be55a9e0 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:24:23 -0600 Subject: [PATCH 04/11] Update repo for blas-devel and lapack-devel. --- base/centos8/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index b8edb32..912eede 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -22,7 +22,7 @@ RUN yum -y update && \ texlive-times texlive-makeindex texlive-helvetic texlive-courier texlive-gsftopk texlive-dvips texlive-mfware texlive-dvisvgm && \ pip3 install rst2pdf sphinx sphinxcontrib-programoutput && \ pip3 install git+https://github.com/esmci/sphinx_rtd_theme.git@version-dropdown-with-fixes && \ - dnf --enablerepo=powertools install -y blas-devel lapack-devel && \ + dnf --enablerepo=ol9_codeready_builder install -y blas-devel lapack-devel && \ ln -s /usr/bin/python3 /usr/bin/python && \ echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf && \ ldconfig && \ From 08f226b70be9de337f829b5c4154099f35cb419a Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:28:40 -0600 Subject: [PATCH 05/11] Resolve a gfortran error. "The Fortran compiler gfortran will not compile files that call the same routine with arguments of different types." --- base/centos8/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index 912eede..adc1dd6 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -38,6 +38,7 @@ RUN mkdir /tmp/sources && \ wget -q http://www.mpich.org/static/downloads/3.3.2/mpich-3.3.2.tar.gz && \ tar zxf mpich-3.3.2.tar.gz && \ cd mpich-3.3.2 && \ + FFLAGS="-w -fallow-argument-mismatch -O2" \ ./configure --prefix=/usr/local && \ make -j 2 install && \ rm -rf /tmp/sources From ae71e60e2123e8e68e39e6c9c935047b7f9dece2 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:49:24 -0600 Subject: [PATCH 06/11] Break up installation of HDF5, netCDF, and PnetCDF. Makes troubleshooting easier. --- base/centos8/Dockerfile | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index adc1dd6..d2d3a3b 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -53,22 +53,25 @@ RUN mkdir /tmp/sources && \ tar zxf hdf5-1.12.0.tar.gz && \ cd hdf5-1.12.0 && \ ./configure --prefix=/usr/local && \ - make -j 2 install && \ - cd /tmp/sources && \ + make -j 2 install + +RUN cd /tmp/sources && \ wget -q ftp://ftp.unidata.ucar.edu/pub/netcdf/netcdf-c-4.7.4.tar.gz && \ tar zxf netcdf-c-4.7.4.tar.gz && \ cd netcdf-c-4.7.4 && \ ./configure --prefix=/usr/local && \ make -j 2 install && \ - ldconfig && \ - cd /tmp/sources && \ + ldconfig + +RUN cd /tmp/sources && \ wget -q ftp://ftp.unidata.ucar.edu/pub/netcdf/netcdf-fortran-4.5.3.tar.gz && \ tar zxf netcdf-fortran-4.5.3.tar.gz && \ cd netcdf-fortran-4.5.3 && \ ./configure --prefix=/usr/local && \ make -j 2 install && \ - ldconfig && \ - cd /tmp/sources && \ + ldconfig + +RUN cd /tmp/sources && \ wget -q https://parallel-netcdf.github.io/Release/pnetcdf-1.12.1.tar.gz && \ tar zxf pnetcdf-1.12.1.tar.gz && \ cd pnetcdf-1.12.1 && \ From a26798467be70175b1636dd2b03254083b5304d1 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 14:50:52 -0600 Subject: [PATCH 07/11] Update netcdf package links. Resolves ESCOMP/ESCOMP-Containers#14. --- base/centos8/Dockerfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index d2d3a3b..532c33a 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -56,16 +56,16 @@ RUN mkdir /tmp/sources && \ make -j 2 install RUN cd /tmp/sources && \ - wget -q ftp://ftp.unidata.ucar.edu/pub/netcdf/netcdf-c-4.7.4.tar.gz && \ - tar zxf netcdf-c-4.7.4.tar.gz && \ + wget -q https://github.com/Unidata/netcdf-c/archive/refs/tags/v4.7.4.tar.gz && \ + tar zxf v4.7.4.tar.gz && \ cd netcdf-c-4.7.4 && \ ./configure --prefix=/usr/local && \ make -j 2 install && \ ldconfig RUN cd /tmp/sources && \ - wget -q ftp://ftp.unidata.ucar.edu/pub/netcdf/netcdf-fortran-4.5.3.tar.gz && \ - tar zxf netcdf-fortran-4.5.3.tar.gz && \ + wget -q https://github.com/Unidata/netcdf-fortran/archive/refs/tags/v4.5.3.tar.gz && \ + tar zxf v4.5.3.tar.gz && \ cd netcdf-fortran-4.5.3 && \ ./configure --prefix=/usr/local && \ make -j 2 install && \ From b455099b982b42c6ad4f7a282370279f34e175b3 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 15:01:12 -0600 Subject: [PATCH 08/11] Failed attempt to resolve pnetcdf compiler error. As suggested at https://github.com/Parallel-NetCDF/Parallel-NetCDF.github.io/blob/master/Release_notes/1.12.2.md --- base/centos8/Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index 532c33a..76f12c6 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -75,7 +75,11 @@ RUN cd /tmp/sources && \ wget -q https://parallel-netcdf.github.io/Release/pnetcdf-1.12.1.tar.gz && \ tar zxf pnetcdf-1.12.1.tar.gz && \ cd pnetcdf-1.12.1 && \ + FFLAGS="-w -fallow-argument-mismatch" \ + FCLAGS="-w -fallow-argument-mismatch" \ ./configure --prefix=/usr/local && \ + FFLAGS="-w -fallow-argument-mismatch" \ + FCLAGS="-w -fallow-argument-mismatch" \ make -j 2 install && \ ldconfig && \ rm -rf /tmp/sources From c111b56f61e59a0863e3df2080db5bffe4fd5107 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 15:04:15 -0600 Subject: [PATCH 09/11] Update pnetcdf from 1.12.1 to 1.12.2. Resolves build error. --- base/centos8/Dockerfile | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/base/centos8/Dockerfile b/base/centos8/Dockerfile index 76f12c6..f36be82 100644 --- a/base/centos8/Dockerfile +++ b/base/centos8/Dockerfile @@ -72,14 +72,10 @@ RUN cd /tmp/sources && \ ldconfig RUN cd /tmp/sources && \ - wget -q https://parallel-netcdf.github.io/Release/pnetcdf-1.12.1.tar.gz && \ - tar zxf pnetcdf-1.12.1.tar.gz && \ - cd pnetcdf-1.12.1 && \ - FFLAGS="-w -fallow-argument-mismatch" \ - FCLAGS="-w -fallow-argument-mismatch" \ + wget -q https://parallel-netcdf.github.io/Release/pnetcdf-1.12.2.tar.gz && \ + tar zxf pnetcdf-1.12.2.tar.gz && \ + cd pnetcdf-1.12.2 && \ ./configure --prefix=/usr/local && \ - FFLAGS="-w -fallow-argument-mismatch" \ - FCLAGS="-w -fallow-argument-mismatch" \ make -j 2 install && \ ldconfig && \ rm -rf /tmp/sources From 930606eca36f237399a1b6b674beb14d6bbe790c Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 15:27:36 -0600 Subject: [PATCH 10/11] Replace CentOS references with OracleLinux. --- base/{centos8 => oraclelinux9}/Dockerfile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) rename base/{centos8 => oraclelinux9}/Dockerfile (94%) diff --git a/base/centos8/Dockerfile b/base/oraclelinux9/Dockerfile similarity index 94% rename from base/centos8/Dockerfile rename to base/oraclelinux9/Dockerfile index f36be82..97eeab2 100644 --- a/base/centos8/Dockerfile +++ b/base/oraclelinux9/Dockerfile @@ -1,10 +1,9 @@ ################################################################################################################ -# escomp/base-centos8 Dockerfile # +# escomp/base-oraclelinux9e # #--------------------------------------------------------------------------------------------------------------# -# A base CentOS8 install + MPI, HDF5, NetCDF and PNetCDF, as well as other core packages for escomp containers # +# A base OracleLinux9 install + MPI, HDF5, NetCDF and PNetCDF, plus other core packages for escomp containers # ################################################################################################################ -# Use latest CentOS8 clone hosted by Oracle: FROM oraclelinux:9 # First, we upate the default packages and install some other necessary ones - while this may give From aa1c009a6fe5ed0e41d5734e260ee645909637c5 Mon Sep 17 00:00:00 2001 From: Sam Rabin Date: Wed, 2 Oct 2024 12:39:39 -0600 Subject: [PATCH 11/11] Add sphinx_mdinclude. --- base/oraclelinux9/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/base/oraclelinux9/Dockerfile b/base/oraclelinux9/Dockerfile index 97eeab2..2a603bf 100644 --- a/base/oraclelinux9/Dockerfile +++ b/base/oraclelinux9/Dockerfile @@ -21,6 +21,7 @@ RUN yum -y update && \ texlive-times texlive-makeindex texlive-helvetic texlive-courier texlive-gsftopk texlive-dvips texlive-mfware texlive-dvisvgm && \ pip3 install rst2pdf sphinx sphinxcontrib-programoutput && \ pip3 install git+https://github.com/esmci/sphinx_rtd_theme.git@version-dropdown-with-fixes && \ + pip3 install sphinx_mdinclude && \ dnf --enablerepo=ol9_codeready_builder install -y blas-devel lapack-devel && \ ln -s /usr/bin/python3 /usr/bin/python && \ echo '/usr/local/lib' > /etc/ld.so.conf.d/local.conf && \