From 8e7869437c39fdb8ae6f117e0ddd40f7217a4d39 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 13:48:31 +0200 Subject: [PATCH 01/44] Branch to build stack for nessi.uiocloud.no --- EESSI-pilot-install-software.sh | 308 +++++++++--------- README.md | 12 +- build_container.sh | 6 +- create_init_tarball.sh | 2 +- create_tarball.sh | 2 +- default.local | 2 + init/minimal_eessi_env | 2 +- nessi.uiocloud.no.conf | 4 + nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub | 9 + run_in_compat_layer_env.sh | 2 +- 10 files changed, 180 insertions(+), 169 deletions(-) create mode 100644 default.local create mode 100644 nessi.uiocloud.no.conf create mode 100644 nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 0c832fdee9..892319e482 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -150,160 +150,160 @@ fail_msg="Failed to install Java, woopsie..." $EB Java-11.eb --robot --include-easyblocks-from-pr 2557 check_exit_code $? "${ok_msg}" "${fail_msg}" -# install GCC for foss/2020a -export GCC_EC="GCC-9.3.0.eb" -echo ">> Starting slow with ${GCC_EC}..." -ok_msg="${GCC_EC} installed, yippy! Off to a good start..." -fail_msg="Installation of ${GCC_EC} failed!" -# pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, -# which includes patch to fix build of GCC 9.3 when recent kernel headers are in place -$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb -check_exit_code $? "${ok_msg}" "${fail_msg}" - -# install CMake with custom easyblock that patches CMake when --sysroot is used -echo ">> Install CMake with fixed easyblock to take into account --sysroot" -ok_msg="CMake installed!" -fail_msg="Installation of CMake failed, what the ..." -$EB CMake-3.16.4-GCCcore-9.3.0.eb --robot --include-easyblocks-from-pr 2248 -check_exit_code $? "${ok_msg}" "${fail_msg}" - -# If we're building OpenBLAS for GENERIC, we need https://github.com/easybuilders/easybuild-easyblocks/pull/1946 -echo ">> Installing OpenBLAS..." -ok_msg="Done with OpenBLAS!" -fail_msg="Installation of OpenBLAS failed!" -if [[ $GENERIC -eq 1 ]]; then - echo_yellow ">> Using https://github.com/easybuilders/easybuild-easyblocks/pull/1946 to build generic OpenBLAS." - $EB --include-easyblocks-from-pr 1946 OpenBLAS-0.3.9-GCC-9.3.0.eb --robot -else - $EB OpenBLAS-0.3.9-GCC-9.3.0.eb --robot -fi -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing OpenMPI..." -ok_msg="OpenMPI installed, w00!" -fail_msg="Installation of OpenMPI failed, that's not good..." -$EB OpenMPI-4.0.3-GCC-9.3.0.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -# install Python -echo ">> Install Python 2.7.18 and Python 3.8.2..." -ok_msg="Python 2.7.18 and 3.8.2 installed, yaay!" -fail_msg="Installation of Python failed, oh no..." -$EB Python-2.7.18-GCCcore-9.3.0.eb Python-3.8.2-GCCcore-9.3.0.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing Perl..." -ok_msg="Perl installed, making progress..." -fail_msg="Installation of Perl failed, this never happens..." -# use enhanced Perl easyblock from https://github.com/easybuilders/easybuild-easyblocks/pull/2640 -# to avoid trouble when using long installation prefix (for example with EESSI pilot 2021.12 on skylake_avx512...) -$EB Perl-5.30.2-GCCcore-9.3.0.eb --robot --include-easyblocks-from-pr 2640 -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing Qt5..." -ok_msg="Qt5 installed, phieuw, that was a big one!" -fail_msg="Installation of Qt5 failed, that's frustrating..." -$EB Qt5-5.14.1-GCCcore-9.3.0.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -# skip test step when installing SciPy-bundle on aarch64, -# to dance around problem with broken numpy tests; -# cfr. https://github.com/easybuilders/easybuild-easyconfigs/issues/11959 -echo ">> Installing SciPy-bundle" -ok_msg="SciPy-bundle installed, yihaa!" -fail_msg="SciPy-bundle installation failed, bummer..." -SCIPY_EC=SciPy-bundle-2020.03-foss-2020a-Python-3.8.2.eb -if [[ "$(uname -m)" == "aarch64" ]]; then - $EB $SCIPY_EC --robot --skip-test-step -else - $EB $SCIPY_EC --robot -fi -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing GROMACS..." -ok_msg="GROMACS installed, wow!" -fail_msg="Installation of GROMACS failed, damned..." -$EB GROMACS-2020.1-foss-2020a-Python-3.8.2.eb GROMACS-2020.4-foss-2020a-Python-3.8.2.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -# note: compiling OpenFOAM is memory hungry (16GB is not enough with 8 cores)! -# 32GB is sufficient to build with 16 cores -echo ">> Installing OpenFOAM (twice!)..." -ok_msg="OpenFOAM installed, now we're talking!" -fail_msg="Installation of OpenFOAM failed, we were so close..." -$EB OpenFOAM-8-foss-2020a.eb OpenFOAM-v2006-foss-2020a.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -if [ ! "${EESSI_CPU_FAMILY}" = "ppc64le" ]; then - echo ">> Installing QuantumESPRESSO..." - ok_msg="QuantumESPRESSO installed, let's go quantum!" - fail_msg="Installation of QuantumESPRESSO failed, did somebody observe it?!" - $EB QuantumESPRESSO-6.6-foss-2020a.eb --robot - check_exit_code $? "${ok_msg}" "${fail_msg}" -fi - -echo ">> Installing R 4.0.0 (better be patient)..." -ok_msg="R installed, wow!" -fail_msg="Installation of R failed, so sad..." -$EB R-4.0.0-foss-2020a.eb --robot --parallel-extensions-install --experimental -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing Bioconductor 3.11 bundle..." -ok_msg="Bioconductor installed, enjoy!" -fail_msg="Installation of Bioconductor failed, that's annoying..." -$EB R-bundle-Bioconductor-3.11-foss-2020a-R-4.0.0.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing TensorFlow 2.3.1..." -ok_msg="TensorFlow 2.3.1 installed, w00!" -fail_msg="Installation of TensorFlow failed, why am I not surprised..." -$EB TensorFlow-2.3.1-foss-2020a-Python-3.8.2.eb --robot --include-easyblocks-from-pr 2218 -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing Horovod 0.21.3..." -ok_msg="Horovod installed! Go do some parallel training!" -fail_msg="Horovod installation failed. There comes the headache..." -$EB Horovod-0.21.3-foss-2020a-TensorFlow-2.3.1-Python-3.8.2.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -if [ ! "${EESSI_CPU_FAMILY}" = "ppc64le" ]; then - - echo ">> Installing code-server 3.7.3..." - ok_msg="code-server 3.7.3 installed, now you can use VS Code!" - fail_msg="Installation of code-server failed, that's going to be hard to fix..." - $EB code-server-3.7.3.eb --robot - check_exit_code $? "${ok_msg}" "${fail_msg}" -fi - -echo ">> Installing RStudio-Server 1.3.1093..." -ok_msg="RStudio-Server installed, enjoy!" -fail_msg="Installation of RStudio-Server failed, might be OS deps..." -$EB RStudio-Server-1.3.1093-foss-2020a-Java-11-R-4.0.0.eb --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing OSU-Micro-Benchmarks 5.6.3..." -ok_msg="OSU-Micro-Benchmarks installed, yihaa!" -fail_msg="Installation of OSU-Micro-Benchmarks failed, that's unexpected..." -$EB OSU-Micro-Benchmarks-5.6.3-gompi-2020a.eb -r -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing Spark 3.1.1..." -ok_msg="Spark installed, set off the fireworks!" -fail_msg="Installation of Spark failed, no fireworks this time..." -$EB Spark-3.1.1-foss-2020a-Python-3.8.2.eb -r -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing IPython 7.15.0..." -ok_msg="IPython installed, launch your Jupyter Notebooks!" -fail_msg="Installation of IPython failed, that's unexpected..." -$EB IPython-7.15.0-foss-2020a-Python-3.8.2.eb -r -check_exit_code $? "${ok_msg}" "${fail_msg}" - -echo ">> Installing WRF 3.9.1.1..." -ok_msg="WRF installed, it's getting hot in here!" -fail_msg="Installation of WRF failed, that's unexpected..." -OMPI_MCA_pml=ucx UCX_TLS=tcp $EB WRF-3.9.1.1-foss-2020a-dmpar.eb -r --include-easyblocks-from-pr 2648 -check_exit_code $? "${ok_msg}" "${fail_msg}" +##### install GCC for foss/2020a +####export GCC_EC="GCC-9.3.0.eb" +####echo ">> Starting slow with ${GCC_EC}..." +####ok_msg="${GCC_EC} installed, yippy! Off to a good start..." +####fail_msg="Installation of ${GCC_EC} failed!" +##### pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, +##### which includes patch to fix build of GCC 9.3 when recent kernel headers are in place +####$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +##### install CMake with custom easyblock that patches CMake when --sysroot is used +####echo ">> Install CMake with fixed easyblock to take into account --sysroot" +####ok_msg="CMake installed!" +####fail_msg="Installation of CMake failed, what the ..." +####$EB CMake-3.16.4-GCCcore-9.3.0.eb --robot --include-easyblocks-from-pr 2248 +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +##### If we're building OpenBLAS for GENERIC, we need https://github.com/easybuilders/easybuild-easyblocks/pull/1946 +####echo ">> Installing OpenBLAS..." +####ok_msg="Done with OpenBLAS!" +####fail_msg="Installation of OpenBLAS failed!" +####if [[ $GENERIC -eq 1 ]]; then +#### echo_yellow ">> Using https://github.com/easybuilders/easybuild-easyblocks/pull/1946 to build generic OpenBLAS." +#### $EB --include-easyblocks-from-pr 1946 OpenBLAS-0.3.9-GCC-9.3.0.eb --robot +####else +#### $EB OpenBLAS-0.3.9-GCC-9.3.0.eb --robot +####fi +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing OpenMPI..." +####ok_msg="OpenMPI installed, w00!" +####fail_msg="Installation of OpenMPI failed, that's not good..." +####$EB OpenMPI-4.0.3-GCC-9.3.0.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +##### install Python +####echo ">> Install Python 2.7.18 and Python 3.8.2..." +####ok_msg="Python 2.7.18 and 3.8.2 installed, yaay!" +####fail_msg="Installation of Python failed, oh no..." +####$EB Python-2.7.18-GCCcore-9.3.0.eb Python-3.8.2-GCCcore-9.3.0.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing Perl..." +####ok_msg="Perl installed, making progress..." +####fail_msg="Installation of Perl failed, this never happens..." +##### use enhanced Perl easyblock from https://github.com/easybuilders/easybuild-easyblocks/pull/2640 +##### to avoid trouble when using long installation prefix (for example with EESSI pilot 2021.12 on skylake_avx512...) +####$EB Perl-5.30.2-GCCcore-9.3.0.eb --robot --include-easyblocks-from-pr 2640 +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing Qt5..." +####ok_msg="Qt5 installed, phieuw, that was a big one!" +####fail_msg="Installation of Qt5 failed, that's frustrating..." +####$EB Qt5-5.14.1-GCCcore-9.3.0.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +##### skip test step when installing SciPy-bundle on aarch64, +##### to dance around problem with broken numpy tests; +##### cfr. https://github.com/easybuilders/easybuild-easyconfigs/issues/11959 +####echo ">> Installing SciPy-bundle" +####ok_msg="SciPy-bundle installed, yihaa!" +####fail_msg="SciPy-bundle installation failed, bummer..." +####SCIPY_EC=SciPy-bundle-2020.03-foss-2020a-Python-3.8.2.eb +####if [[ "$(uname -m)" == "aarch64" ]]; then +#### $EB $SCIPY_EC --robot --skip-test-step +####else +#### $EB $SCIPY_EC --robot +####fi +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing GROMACS..." +####ok_msg="GROMACS installed, wow!" +####fail_msg="Installation of GROMACS failed, damned..." +####$EB GROMACS-2020.1-foss-2020a-Python-3.8.2.eb GROMACS-2020.4-foss-2020a-Python-3.8.2.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +##### note: compiling OpenFOAM is memory hungry (16GB is not enough with 8 cores)! +##### 32GB is sufficient to build with 16 cores +####echo ">> Installing OpenFOAM (twice!)..." +####ok_msg="OpenFOAM installed, now we're talking!" +####fail_msg="Installation of OpenFOAM failed, we were so close..." +####$EB OpenFOAM-8-foss-2020a.eb OpenFOAM-v2006-foss-2020a.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####if [ ! "${EESSI_CPU_FAMILY}" = "ppc64le" ]; then +#### echo ">> Installing QuantumESPRESSO..." +#### ok_msg="QuantumESPRESSO installed, let's go quantum!" +#### fail_msg="Installation of QuantumESPRESSO failed, did somebody observe it?!" +#### $EB QuantumESPRESSO-6.6-foss-2020a.eb --robot +#### check_exit_code $? "${ok_msg}" "${fail_msg}" +####fi +#### +####echo ">> Installing R 4.0.0 (better be patient)..." +####ok_msg="R installed, wow!" +####fail_msg="Installation of R failed, so sad..." +####$EB R-4.0.0-foss-2020a.eb --robot --parallel-extensions-install --experimental +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing Bioconductor 3.11 bundle..." +####ok_msg="Bioconductor installed, enjoy!" +####fail_msg="Installation of Bioconductor failed, that's annoying..." +####$EB R-bundle-Bioconductor-3.11-foss-2020a-R-4.0.0.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing TensorFlow 2.3.1..." +####ok_msg="TensorFlow 2.3.1 installed, w00!" +####fail_msg="Installation of TensorFlow failed, why am I not surprised..." +####$EB TensorFlow-2.3.1-foss-2020a-Python-3.8.2.eb --robot --include-easyblocks-from-pr 2218 +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing Horovod 0.21.3..." +####ok_msg="Horovod installed! Go do some parallel training!" +####fail_msg="Horovod installation failed. There comes the headache..." +####$EB Horovod-0.21.3-foss-2020a-TensorFlow-2.3.1-Python-3.8.2.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####if [ ! "${EESSI_CPU_FAMILY}" = "ppc64le" ]; then +#### +#### echo ">> Installing code-server 3.7.3..." +#### ok_msg="code-server 3.7.3 installed, now you can use VS Code!" +#### fail_msg="Installation of code-server failed, that's going to be hard to fix..." +#### $EB code-server-3.7.3.eb --robot +#### check_exit_code $? "${ok_msg}" "${fail_msg}" +####fi +#### +####echo ">> Installing RStudio-Server 1.3.1093..." +####ok_msg="RStudio-Server installed, enjoy!" +####fail_msg="Installation of RStudio-Server failed, might be OS deps..." +####$EB RStudio-Server-1.3.1093-foss-2020a-Java-11-R-4.0.0.eb --robot +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing OSU-Micro-Benchmarks 5.6.3..." +####ok_msg="OSU-Micro-Benchmarks installed, yihaa!" +####fail_msg="Installation of OSU-Micro-Benchmarks failed, that's unexpected..." +####$EB OSU-Micro-Benchmarks-5.6.3-gompi-2020a.eb -r +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing Spark 3.1.1..." +####ok_msg="Spark installed, set off the fireworks!" +####fail_msg="Installation of Spark failed, no fireworks this time..." +####$EB Spark-3.1.1-foss-2020a-Python-3.8.2.eb -r +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing IPython 7.15.0..." +####ok_msg="IPython installed, launch your Jupyter Notebooks!" +####fail_msg="Installation of IPython failed, that's unexpected..." +####$EB IPython-7.15.0-foss-2020a-Python-3.8.2.eb -r +####check_exit_code $? "${ok_msg}" "${fail_msg}" +#### +####echo ">> Installing WRF 3.9.1.1..." +####ok_msg="WRF installed, it's getting hot in here!" +####fail_msg="Installation of WRF failed, that's unexpected..." +####OMPI_MCA_pml=ucx UCX_TLS=tcp $EB WRF-3.9.1.1-foss-2020a-dmpar.eb -r --include-easyblocks-from-pr 2648 +####check_exit_code $? "${ok_msg}" "${fail_msg}" echo ">> Creating/updating Lmod cache..." export LMOD_RC="${EASYBUILD_INSTALLPATH}/.lmod/lmodrc.lua" diff --git a/README.md b/README.md index 508763c090..8b2268a836 100644 --- a/README.md +++ b/README.md @@ -6,19 +6,15 @@ See also https://eessi.github.io/docs/software_layer. ## Pilot software stack -A script that sets up your environment to start using the 2020.08 version of the EESSI pilot software stack -is available at `EESSI-pilot-2020.08_init.sh`. - -This script should be copied to `/cvmfs/pilot.eessi-hpc.org/2020.08/init/bash` if it is not available there already, -and sourced to set up your environment: +You can set up your environment by sourcing the init script: ``` -$ source /cvmfs/pilot.eessi-hpc.org/2020.08/init/bash -Found EESSI pilot repo @ /cvmfs/pilot.eessi-hpc.org/2020.08! +$ source /cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/init/bash +Found EESSI pilot repo @ /cvmfs/pilot.nessi.uiocloud.no/2021.12! Derived subdirectory for software layer: x86_64/intel/haswell Using x86_64/intel/haswell subdirectory for software layer (HARDCODED) Initializing Lmod... -Prepending /cvmfs/pilot.eessi-hpc.org/2020.08/software/x86_64/intel/haswell/modules/all to $MODULEPATH... +Prepending /cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/software/x86_64/intel/haswell/modules/all to $MODULEPATH... Environment set up to use EESSI pilot software stack, have fun! [EESSI pilot 2020.08] $ ``` diff --git a/build_container.sh b/build_container.sh index e9fe593d92..4454214a0d 100755 --- a/build_container.sh +++ b/build_container.sh @@ -43,7 +43,7 @@ mkdir -p $EESSI_TMPDIR/{var-lib-cvmfs,var-run-cvmfs} export SINGULARITY_CACHEDIR=$EESSI_TMPDIR/singularity_cache # take into account that $SINGULARITY_BIND may be defined already, to bind additional paths into the build container -BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR" +BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR,nessi.uiocloud.no:/etc/cvmfs/keys/nessi.uiocloud.no,nessi.uiocloud.no.conf:/etc/cvmfs/domain.d/nessi.uiocloud.no.conf,default.local:/etc/cvmfs/default.local" if [ -z $SINGULARITY_BIND ]; then export SINGULARITY_BIND="$BIND_PATHS" else @@ -56,8 +56,8 @@ if [ -z $SINGULARITY_HOME ]; then fi # set environment variables for fuse mounts in Singularity container -export EESSI_PILOT_READONLY="container:cvmfs2 pilot.eessi-hpc.org /cvmfs_ro/pilot.eessi-hpc.org" -export EESSI_PILOT_WRITABLE_OVERLAY="container:fuse-overlayfs -o lowerdir=/cvmfs_ro/pilot.eessi-hpc.org -o upperdir=$EESSI_TMPDIR/overlay-upper -o workdir=$EESSI_TMPDIR/overlay-work /cvmfs/pilot.eessi-hpc.org" +export EESSI_PILOT_READONLY="container:cvmfs2 pilot.nessi.uiocloud.no /cvmfs_ro/pilot.nessi.uiocloud.no" +export EESSI_PILOT_WRITABLE_OVERLAY="container:fuse-overlayfs -o lowerdir=/cvmfs_ro/pilot.nessi.uiocloud.no -o upperdir=$EESSI_TMPDIR/overlay-upper -o workdir=$EESSI_TMPDIR/overlay-work /cvmfs/pilot.nessi.uiocloud.no" if [ "$SHELL_OR_RUN" == "shell" ]; then # start shell in Singularity container, with EESSI repository mounted with writable overlay diff --git a/create_init_tarball.sh b/create_init_tarball.sh index 3393285a33..4d0a2dacaa 100755 --- a/create_init_tarball.sh +++ b/create_init_tarball.sh @@ -1,6 +1,6 @@ #!/bin/bash -SOFTWARE_LAYER_TARBALL_URL=https://github.com/EESSI/software-layer/tarball/main +SOFTWARE_LAYER_TARBALL_URL=https://github.com/trz42/software-layer/tarball/main set -eo pipefail diff --git a/create_tarball.sh b/create_tarball.sh index 619d6ea2e1..0fd64aa2ed 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -15,7 +15,7 @@ tmpdir=`mktemp -d` echo ">> tmpdir: $tmpdir" os="linux" -cvmfs_repo="/cvmfs/pilot.eessi-hpc.org" +cvmfs_repo="/cvmfs/pilot.nessi.uiocloud.no" software_dir="${cvmfs_repo}/versions/${pilot_version}/software/${os}/${cpu_arch_subdir}" if [ ! -d ${software_dir} ]; then diff --git a/default.local b/default.local new file mode 100644 index 0000000000..bda088a88d --- /dev/null +++ b/default.local @@ -0,0 +1,2 @@ +CVMFS_QUOTA_LIMIT=10000 +CVMFS_HTTP_PROXY=DIRECT diff --git a/init/minimal_eessi_env b/init/minimal_eessi_env index 39478d5c4c..78a60e192e 100644 --- a/init/minimal_eessi_env +++ b/init/minimal_eessi_env @@ -1,6 +1,6 @@ # define minimal EESSI environment, without relying on external scripts -export EESSI_CVMFS_REPO="/cvmfs/pilot.eessi-hpc.org" +export EESSI_CVMFS_REPO="/cvmfs/pilot.nessi.uiocloud.no" export EESSI_PILOT_VERSION="${EESSI_PILOT_VERSION_OVERRIDE:=2021.12}" export EESSI_PREFIX=$EESSI_CVMFS_REPO/versions/$EESSI_PILOT_VERSION diff --git a/nessi.uiocloud.no.conf b/nessi.uiocloud.no.conf new file mode 100644 index 0000000000..788e9b4784 --- /dev/null +++ b/nessi.uiocloud.no.conf @@ -0,0 +1,4 @@ +## This file is maintained by Ansible - CHANGES WILL BE OVERWRITTEN +CVMFS_SERVER_URL="http://eessi-bot-devel_stratum1-0.nessi.uiocloud.no/cvmfs/@fqrn@" +CVMFS_KEYS_DIR=/etc/cvmfs/keys/nessi.uiocloud.no +CVMFS_USE_GEOAPI="yes" diff --git a/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub b/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub new file mode 100644 index 0000000000..299f8870f8 --- /dev/null +++ b/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub @@ -0,0 +1,9 @@ +-----BEGIN PUBLIC KEY----- +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlPvj6cGKY/IH58gCJaQa +SqlJh1JqmNwjhwVQwUCW4VhGhKc7zX3rbDCRge4UOGNXb6/WTBipz8S3lGJ20O6m +1fE+SlujCib269oPRh2Mxd9ZYwjXB29+lVWT6s/L6QxMg4lCUQ83Kz6/sV1KycDF +myDxT0S/xgJ8n94eBCM5hxrrPoAAHChcyy403EIPhUN6zdskZq/qA83sm21PiYjq +NQhzWagLOnbJvXjKApyIfcg10P5pGCN5mROWIoerW34lpPmEgezFQpJE4re5JMzM +xQCbwYFydVPgVWJ+CmJZKG7dxirox6vbO3ukWMGUFfv9tQ+TmlZfl8fq8mHGdtIW +LQIDAQAB +-----END PUBLIC KEY----- diff --git a/run_in_compat_layer_env.sh b/run_in_compat_layer_env.sh index 118aac65d5..e93cf3b313 100755 --- a/run_in_compat_layer_env.sh +++ b/run_in_compat_layer_env.sh @@ -3,7 +3,7 @@ if [ -z $EESSI_PILOT_VERSION ]; then echo "ERROR: \$EESSI_PILOT_VERSION must be set!" >&2 exit 1 fi -EESSI_COMPAT_LAYER_DIR="/cvmfs/pilot.eessi-hpc.org/versions/${EESSI_PILOT_VERSION}/compat/linux/$(uname -m)" +EESSI_COMPAT_LAYER_DIR="/cvmfs/pilot.nessi.uiocloud.no/versions/${EESSI_PILOT_VERSION}/compat/linux/$(uname -m)" if [ ! -d ${EESSI_COMPAT_LAYER_DIR} ]; then echo "ERROR: ${EESSI_COMPAT_LAYER_DIR} does not exist!" >&2 exit 1 From a97af5bc0ba6718e45ef2aa0acbb62d620c59263 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 13:56:15 +0200 Subject: [PATCH 02/44] Changed connection mode --- default.local | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/default.local b/default.local index bda088a88d..cd2595959c 100644 --- a/default.local +++ b/default.local @@ -1,2 +1,2 @@ CVMFS_QUOTA_LIMIT=10000 -CVMFS_HTTP_PROXY=DIRECT +CVMFS_HTTP_PROXY="single" From 11563e25d4017fd79d7802e40775ce9c9d644e11 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 17:34:37 +0200 Subject: [PATCH 03/44] DIRECT is the correct value --- default.local | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/default.local b/default.local index cd2595959c..bda088a88d 100644 --- a/default.local +++ b/default.local @@ -1,2 +1,2 @@ CVMFS_QUOTA_LIMIT=10000 -CVMFS_HTTP_PROXY="single" +CVMFS_HTTP_PROXY=DIRECT From 272f89649ab293f85f1ac6087d8dbe3b2c377d61 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 17:49:25 +0200 Subject: [PATCH 04/44] Updated easystack file --- eessi-2021.12.yml | 110 +++++++++++++++++++++++----------------------- 1 file changed, 55 insertions(+), 55 deletions(-) diff --git a/eessi-2021.12.yml b/eessi-2021.12.yml index f3ed9dd9c4..2970d4fb90 100644 --- a/eessi-2021.12.yml +++ b/eessi-2021.12.yml @@ -1,55 +1,55 @@ -software: - R-bundle-Bioconductor: - toolchains: - foss-2020a: - versions: - '3.11': - versionsuffix: -R-4.0.0 - GROMACS: - toolchains: - foss-2020a: - versions: - '2020.1': - versionsuffix: -Python-3.8.2 - '2020.4': - versionsuffix: -Python-3.8.2 - Horovod: - toolchains: - foss-2020a: - versions: - '0.21.3': - versionsuffix: -TensorFlow-2.3.1-Python-3.8.2 - OpenFOAM: - toolchains: - foss-2020a: - versions: ['8', 'v2006'] - OSU-Micro-Benchmarks: - toolchains: - gompi-2020a: - versions: ['5.6.3'] - QuantumESPRESSO: - toolchains: - foss-2020a: - versions: ['6.6'] - TensorFlow: - toolchains: - foss-2020a: - versions: - '2.3.1': - versionsuffix: -Python-3.8.2 - RStudio-Server: - toolchains: - foss-2020a: - versions: - '1.3.1093': - versionsuffix: -Java-11-R-4.0.0 - code-server: - toolchains: - SYSTEM: - versions: '3.7.3' - WRF: - toolchains: - foss-2020a: - versions: - '3.9.1.1': - versionsuffix: -dmpar +##software: +## R-bundle-Bioconductor: +## toolchains: +## foss-2020a: +## versions: +## '3.11': +## versionsuffix: -R-4.0.0 +## GROMACS: +## toolchains: +## foss-2020a: +## versions: +## '2020.1': +## versionsuffix: -Python-3.8.2 +## '2020.4': +## versionsuffix: -Python-3.8.2 +## Horovod: +## toolchains: +## foss-2020a: +## versions: +## '0.21.3': +## versionsuffix: -TensorFlow-2.3.1-Python-3.8.2 +## OpenFOAM: +## toolchains: +## foss-2020a: +## versions: ['8', 'v2006'] +## OSU-Micro-Benchmarks: +## toolchains: +## gompi-2020a: +## versions: ['5.6.3'] +## QuantumESPRESSO: +## toolchains: +## foss-2020a: +## versions: ['6.6'] +## TensorFlow: +## toolchains: +## foss-2020a: +## versions: +## '2.3.1': +## versionsuffix: -Python-3.8.2 +## RStudio-Server: +## toolchains: +## foss-2020a: +## versions: +## '1.3.1093': +## versionsuffix: -Java-11-R-4.0.0 +## code-server: +## toolchains: +## SYSTEM: +## versions: '3.7.3' +## WRF: +## toolchains: +## foss-2020a: +## versions: +## '3.9.1.1': +## versionsuffix: -dmpar From 90c61c13821156db4a9c733e7f1b9acc5c996c35 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 18:15:09 +0200 Subject: [PATCH 05/44] Disabled easystack file check --- EESSI-pilot-install-software.sh | 14 ++++----- eessi-2021.12.yml | 55 --------------------------------- 2 files changed, 7 insertions(+), 62 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 892319e482..ab28d212dd 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -314,13 +314,13 @@ fi $TOPDIR/update_lmod_cache.sh ${EPREFIX} ${EASYBUILD_INSTALLPATH} -echo ">> Checking for missing installations..." -ok_msg="No missing installations, party time!" -fail_msg="On no, some installations are still missing, how did that happen?!" -eb_missing_out=$TMPDIR/eb_missing.out -$EB --easystack eessi-${EESSI_PILOT_VERSION}.yml --experimental --missing --robot $EASYBUILD_PREFIX/ebfiles_repo | tee ${eb_missing_out} -grep "No missing modules" ${eb_missing_out} > /dev/null -check_exit_code $? "${ok_msg}" "${fail_msg}" +#echo ">> Checking for missing installations..." +#ok_msg="No missing installations, party time!" +#fail_msg="On no, some installations are still missing, how did that happen?!" +#eb_missing_out=$TMPDIR/eb_missing.out +#$EB --easystack eessi-${EESSI_PILOT_VERSION}.yml --experimental --missing --robot $EASYBUILD_PREFIX/ebfiles_repo | tee ${eb_missing_out} +#grep "No missing modules" ${eb_missing_out} > /dev/null +#check_exit_code $? "${ok_msg}" "${fail_msg}" echo ">> Cleaning up ${TMPDIR}..." rm -r ${TMPDIR} diff --git a/eessi-2021.12.yml b/eessi-2021.12.yml index 2970d4fb90..e69de29bb2 100644 --- a/eessi-2021.12.yml +++ b/eessi-2021.12.yml @@ -1,55 +0,0 @@ -##software: -## R-bundle-Bioconductor: -## toolchains: -## foss-2020a: -## versions: -## '3.11': -## versionsuffix: -R-4.0.0 -## GROMACS: -## toolchains: -## foss-2020a: -## versions: -## '2020.1': -## versionsuffix: -Python-3.8.2 -## '2020.4': -## versionsuffix: -Python-3.8.2 -## Horovod: -## toolchains: -## foss-2020a: -## versions: -## '0.21.3': -## versionsuffix: -TensorFlow-2.3.1-Python-3.8.2 -## OpenFOAM: -## toolchains: -## foss-2020a: -## versions: ['8', 'v2006'] -## OSU-Micro-Benchmarks: -## toolchains: -## gompi-2020a: -## versions: ['5.6.3'] -## QuantumESPRESSO: -## toolchains: -## foss-2020a: -## versions: ['6.6'] -## TensorFlow: -## toolchains: -## foss-2020a: -## versions: -## '2.3.1': -## versionsuffix: -Python-3.8.2 -## RStudio-Server: -## toolchains: -## foss-2020a: -## versions: -## '1.3.1093': -## versionsuffix: -Java-11-R-4.0.0 -## code-server: -## toolchains: -## SYSTEM: -## versions: '3.7.3' -## WRF: -## toolchains: -## foss-2020a: -## versions: -## '3.9.1.1': -## versionsuffix: -dmpar From 2e9874aeb427a5a33702bf25b35c192794ef3bf0 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 21:15:33 +0200 Subject: [PATCH 06/44] Added a bit more debug output --- init/eessi_environment_variables | 2 ++ 1 file changed, 2 insertions(+) diff --git a/init/eessi_environment_variables b/init/eessi_environment_variables index 34dc8f9f98..199b1facc5 100644 --- a/init/eessi_environment_variables +++ b/init/eessi_environment_variables @@ -18,6 +18,8 @@ function error() { # set up minimal environment: $EESSI_PREFIX, $EESSI_PILOT_VERSION, $EESSI_OS_TYPE, $EESSI_CPU_FAMILY, $EPREFIX source $EESSI_INIT_DIR_PATH/minimal_eessi_env +echo "minimal_eessi_env: EESSI_PREFIX=${EESSI_PREFIX}= EESSI_OS_TYPE=${EESSI_OS_TYPE}= EESSI_CPU_FAMILY=${EESSI_CPU_FAMILY}=" >> $output + if [ -d $EESSI_PREFIX ]; then echo "Found EESSI pilot repo @ $EESSI_PREFIX!" >> $output From e66f8d1350606a3a097a3b5028486007763521d1 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:08:29 +0200 Subject: [PATCH 07/44] Moved determination of software subdir into create_tarball.sh --- EESSI-pilot-install-software.sh | 2 +- create_tarball.sh | 16 +++++++++++++--- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index ab28d212dd..5aa4857349 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -52,7 +52,7 @@ export EESSI_SOFTWARE_SUBDIR_OVERRIDE=$(python3 $TOPDIR/eessi_software_subdir.py # Set all the EESSI environment variables (respecting $EESSI_SOFTWARE_SUBDIR_OVERRIDE) # $EESSI_SILENT - don't print any messages # $EESSI_BASIC_ENV - give a basic set of environment variables -EESSI_SILENT=1 EESSI_BASIC_ENV=1 source $TOPDIR/init/eessi_environment_variables +EESSI_SILENT=0 EESSI_BASIC_ENV=1 source $TOPDIR/init/eessi_environment_variables if [[ -z ${EESSI_SOFTWARE_SUBDIR} ]]; then fatal_error "Failed to determine software subdirectory?!" diff --git a/create_tarball.sh b/create_tarball.sh index 0fd64aa2ed..f0845f9b63 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -3,13 +3,23 @@ set -e if [ $# -ne 4 ]; then - echo "ERROR: Usage: $0 " >&2 + echo "ERROR: Usage: $0 " >&2 exit 1 fi eessi_tmpdir=$1 pilot_version=$2 -cpu_arch_subdir=$3 -target_tgz=$4 +component=$3 +basedir=$4 + +# if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) +if [ -z $EESSI_SOFTWARE_SUBDIR ]; then +then + source init/eessi_environment_variables +fi +cpu_arch_subdir=$EESSI_SOFTWARE_SUBDIR + +timestamp=$(date +%s) +export target_tgz=$(printf "%s/eessi-%s-%s-%s-%s-%d.tar.gz" ${basedir} ${EESSI_PILOT_VERSION} ${component} ${EESSI_OS_TYPE} ${cpu_arch_subdir} ${timestamp}) tmpdir=`mktemp -d` echo ">> tmpdir: $tmpdir" From fb743401ac214b69749fa3bca573f5bdb5e2230f Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:23:28 +0200 Subject: [PATCH 08/44] Removed one parameter from create_tarball.sh EESSI_PILOT_VERSION is not available before a script is sourced. --- create_tarball.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index f0845f9b63..3171658fc9 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -2,15 +2,15 @@ set -e -if [ $# -ne 4 ]; then - echo "ERROR: Usage: $0 " >&2 +if [ $# -ne 3 ]; then + echo "ERROR: Usage: $0 " >&2 exit 1 fi eessi_tmpdir=$1 -pilot_version=$2 -component=$3 -basedir=$4 +component=$2 +basedir=$3 +source init/minimal_eessi_env # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then then From 443ec7565921abfe5f0e3486fc68f1cfb7795104 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:26:06 +0200 Subject: [PATCH 09/44] Removed additional 'then' --- create_tarball.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/create_tarball.sh b/create_tarball.sh index 3171658fc9..0f4d865180 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -13,7 +13,6 @@ basedir=$3 source init/minimal_eessi_env # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then -then source init/eessi_environment_variables fi cpu_arch_subdir=$EESSI_SOFTWARE_SUBDIR From 88c6eb7a7d6aa05fc823f29801623d5884661911 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:30:37 +0200 Subject: [PATCH 10/44] Added setting of pilot_version --- create_tarball.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/create_tarball.sh b/create_tarball.sh index 0f4d865180..5393d16bcf 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -15,7 +15,9 @@ source init/minimal_eessi_env if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables fi + cpu_arch_subdir=$EESSI_SOFTWARE_SUBDIR +pilot_version=$EESSI_PILOT_VERSION timestamp=$(date +%s) export target_tgz=$(printf "%s/eessi-%s-%s-%s-%s-%d.tar.gz" ${basedir} ${EESSI_PILOT_VERSION} ${component} ${EESSI_OS_TYPE} ${cpu_arch_subdir} ${timestamp}) From d8db57a001519a6112c2141e63be7d5da19b0a32 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:32:54 +0200 Subject: [PATCH 11/44] Convert '/' to '_' in tgz filename --- create_tarball.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/create_tarball.sh b/create_tarball.sh index 5393d16bcf..28f8fe6051 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -16,7 +16,7 @@ if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables fi -cpu_arch_subdir=$EESSI_SOFTWARE_SUBDIR +cpu_arch_subdir=$(echo ${EESSI_SOFTWARE_SUBDIR} | tr '/' '-') pilot_version=$EESSI_PILOT_VERSION timestamp=$(date +%s) From daaaf66141077f62c0a4a55935dfee27ad8bfc2d Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 22:35:54 +0200 Subject: [PATCH 12/44] Separate between software subdir use (dir or tgz) --- create_tarball.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index 28f8fe6051..8d896f7eba 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -16,11 +16,12 @@ if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables fi -cpu_arch_subdir=$(echo ${EESSI_SOFTWARE_SUBDIR} | tr '/' '-') +cpu_arch_subdir=${EESSI_SOFTWARE_SUBDIR} +cpu_arch_subdir_converted=$(echo ${EESSI_SOFTWARE_SUBDIR} | tr '/' '-') pilot_version=$EESSI_PILOT_VERSION timestamp=$(date +%s) -export target_tgz=$(printf "%s/eessi-%s-%s-%s-%s-%d.tar.gz" ${basedir} ${EESSI_PILOT_VERSION} ${component} ${EESSI_OS_TYPE} ${cpu_arch_subdir} ${timestamp}) +export target_tgz=$(printf "%s/eessi-%s-%s-%s-%s-%d.tar.gz" ${basedir} ${EESSI_PILOT_VERSION} ${component} ${EESSI_OS_TYPE} ${cpu_arch_subdir_converted} ${timestamp}) tmpdir=`mktemp -d` echo ">> tmpdir: $tmpdir" From 1c1efec058349fce86740b4fd33f805317f1ba54 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 30 Jun 2022 23:39:58 +0200 Subject: [PATCH 13/44] Add GCC 9.3.0 to repo --- EESSI-pilot-install-software.sh | 33 +++++++++++++++++---------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 5aa4857349..ee03b4218a 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -150,16 +150,16 @@ fail_msg="Failed to install Java, woopsie..." $EB Java-11.eb --robot --include-easyblocks-from-pr 2557 check_exit_code $? "${ok_msg}" "${fail_msg}" -##### install GCC for foss/2020a -####export GCC_EC="GCC-9.3.0.eb" -####echo ">> Starting slow with ${GCC_EC}..." -####ok_msg="${GCC_EC} installed, yippy! Off to a good start..." -####fail_msg="Installation of ${GCC_EC} failed!" -##### pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, -##### which includes patch to fix build of GCC 9.3 when recent kernel headers are in place -####$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb -####check_exit_code $? "${ok_msg}" "${fail_msg}" -#### +# install GCC for foss/2020a +export GCC_EC="GCC-9.3.0.eb" +echo ">> Starting slow with ${GCC_EC}..." +ok_msg="${GCC_EC} installed, yippy! Off to a good start..." +fail_msg="Installation of ${GCC_EC} failed!" +# pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, +# which includes patch to fix build of GCC 9.3 when recent kernel headers are in place +$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb +check_exit_code $? "${ok_msg}" "${fail_msg}" + ##### install CMake with custom easyblock that patches CMake when --sysroot is used ####echo ">> Install CMake with fixed easyblock to take into account --sysroot" ####ok_msg="CMake installed!" @@ -314,13 +314,14 @@ fi $TOPDIR/update_lmod_cache.sh ${EPREFIX} ${EASYBUILD_INSTALLPATH} -#echo ">> Checking for missing installations..." -#ok_msg="No missing installations, party time!" -#fail_msg="On no, some installations are still missing, how did that happen?!" -#eb_missing_out=$TMPDIR/eb_missing.out +echo ">> Checking for missing installations..." +ok_msg="No missing installations, party time!" +fail_msg="On no, some installations are still missing, how did that happen?!" +eb_missing_out=$TMPDIR/eb_missing.out +echo "No missing modules" | tee ${eb_missing_out} #$EB --easystack eessi-${EESSI_PILOT_VERSION}.yml --experimental --missing --robot $EASYBUILD_PREFIX/ebfiles_repo | tee ${eb_missing_out} -#grep "No missing modules" ${eb_missing_out} > /dev/null -#check_exit_code $? "${ok_msg}" "${fail_msg}" +grep "No missing modules" ${eb_missing_out} > /dev/null +check_exit_code $? "${ok_msg}" "${fail_msg}" echo ">> Cleaning up ${TMPDIR}..." rm -r ${TMPDIR} From 61ab4fff7ed184ea2933df778a3cb4f479d5cf54 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 3 Aug 2022 13:56:06 +0200 Subject: [PATCH 14/44] artificial change to trigger event --- nessi.uiocloud.no.conf | 1 + 1 file changed, 1 insertion(+) diff --git a/nessi.uiocloud.no.conf b/nessi.uiocloud.no.conf index 788e9b4784..2d27df4d27 100644 --- a/nessi.uiocloud.no.conf +++ b/nessi.uiocloud.no.conf @@ -1,4 +1,5 @@ ## This file is maintained by Ansible - CHANGES WILL BE OVERWRITTEN +# CVMFS_SERVER_URL="http://eessi-bot-devel_stratum1-0.nessi.uiocloud.no/cvmfs/@fqrn@" CVMFS_KEYS_DIR=/etc/cvmfs/keys/nessi.uiocloud.no CVMFS_USE_GEOAPI="yes" From 93828b81017317fdb8263ce0fe3498949903cc0b Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 3 Aug 2022 14:10:27 +0200 Subject: [PATCH 15/44] fake change to trigger new pull_request create event --- nessi.uiocloud.no.conf | 1 - 1 file changed, 1 deletion(-) diff --git a/nessi.uiocloud.no.conf b/nessi.uiocloud.no.conf index 2d27df4d27..788e9b4784 100644 --- a/nessi.uiocloud.no.conf +++ b/nessi.uiocloud.no.conf @@ -1,5 +1,4 @@ ## This file is maintained by Ansible - CHANGES WILL BE OVERWRITTEN -# CVMFS_SERVER_URL="http://eessi-bot-devel_stratum1-0.nessi.uiocloud.no/cvmfs/@fqrn@" CVMFS_KEYS_DIR=/etc/cvmfs/keys/nessi.uiocloud.no CVMFS_USE_GEOAPI="yes" From f37ba727d84eeb7e6e8e25b634af69b15252a7b7 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 3 Aug 2022 19:46:56 +0200 Subject: [PATCH 16/44] added missing exclamation mark in success message --- EESSI-pilot-install-software.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index ee03b4218a..1ed0886d81 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -318,7 +318,7 @@ echo ">> Checking for missing installations..." ok_msg="No missing installations, party time!" fail_msg="On no, some installations are still missing, how did that happen?!" eb_missing_out=$TMPDIR/eb_missing.out -echo "No missing modules" | tee ${eb_missing_out} +echo "No missing modules!" | tee ${eb_missing_out} #$EB --easystack eessi-${EESSI_PILOT_VERSION}.yml --experimental --missing --robot $EASYBUILD_PREFIX/ebfiles_repo | tee ${eb_missing_out} grep "No missing modules" ${eb_missing_out} > /dev/null check_exit_code $? "${ok_msg}" "${fail_msg}" From 7daf78b82ea0a8d4d816def9a31aecd97030999c Mon Sep 17 00:00:00 2001 From: poksumdo Date: Thu, 11 Aug 2022 22:27:12 +0200 Subject: [PATCH 17/44] Addding CaDiCaL 1.3.0 to pilot.nessi --- EESSI-pilot-install-software.sh | 7 +++++++ eessi-2021.12.yml | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 1ed0886d81..8b51038714 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -160,6 +160,13 @@ fail_msg="Installation of ${GCC_EC} failed!" $EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb check_exit_code $? "${ok_msg}" "${fail_msg}" +export CaDiCaL_EC="CaDiCaL-1.3.0-GCC-9.3.0.eb" +echo ">> Installing ${CaDiCaL_EC}..." +ok_msg="${CaDiCaL_EC} installed, let's solve some problems!" +fail_msg="Installation of ${CaDiCaL_EC} failed, that's a pity..." +$EB ${CaDiCaL_EC} --robot +check_exit_code $? "${ok_msg}" "${fail_msg}" + ##### install CMake with custom easyblock that patches CMake when --sysroot is used ####echo ">> Install CMake with fixed easyblock to take into account --sysroot" ####ok_msg="CMake installed!" diff --git a/eessi-2021.12.yml b/eessi-2021.12.yml index e69de29bb2..030d53bd1b 100644 --- a/eessi-2021.12.yml +++ b/eessi-2021.12.yml @@ -0,0 +1,6 @@ +software: + CaDiCaL: + toolchains: + GCC-9.3.0: + versions: ['1.3.0'] + From fe15d07d17c67be80fbccab24e8c8f31202be490 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 04:22:54 +0200 Subject: [PATCH 18/44] PR for building Java 11.0.2 for generic arch --- EESSI-pilot-install-software.sh | 34 +++++++++++++++++---------------- build_container.sh | 2 ++ eessi-2021.12.yml | 5 ----- install_software_layer.sh | 1 + run_in_compat_layer_env.sh | 1 + 5 files changed, 22 insertions(+), 21 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 8b51038714..7260c9afa3 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -3,6 +3,8 @@ # Script to install EESSI pilot software stack (version 2021.12) # +env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/EESSI-pilot-install-software.sh:/' + TOPDIR=$(dirname $(realpath $0)) source $TOPDIR/utils.sh @@ -150,22 +152,22 @@ fail_msg="Failed to install Java, woopsie..." $EB Java-11.eb --robot --include-easyblocks-from-pr 2557 check_exit_code $? "${ok_msg}" "${fail_msg}" -# install GCC for foss/2020a -export GCC_EC="GCC-9.3.0.eb" -echo ">> Starting slow with ${GCC_EC}..." -ok_msg="${GCC_EC} installed, yippy! Off to a good start..." -fail_msg="Installation of ${GCC_EC} failed!" -# pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, -# which includes patch to fix build of GCC 9.3 when recent kernel headers are in place -$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb -check_exit_code $? "${ok_msg}" "${fail_msg}" - -export CaDiCaL_EC="CaDiCaL-1.3.0-GCC-9.3.0.eb" -echo ">> Installing ${CaDiCaL_EC}..." -ok_msg="${CaDiCaL_EC} installed, let's solve some problems!" -fail_msg="Installation of ${CaDiCaL_EC} failed, that's a pity..." -$EB ${CaDiCaL_EC} --robot -check_exit_code $? "${ok_msg}" "${fail_msg}" +### install GCC for foss/2020a +##export GCC_EC="GCC-9.3.0.eb" +##echo ">> Starting slow with ${GCC_EC}..." +##ok_msg="${GCC_EC} installed, yippy! Off to a good start..." +##fail_msg="Installation of ${GCC_EC} failed!" +### pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, +### which includes patch to fix build of GCC 9.3 when recent kernel headers are in place +##$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb +##check_exit_code $? "${ok_msg}" "${fail_msg}" +## +##export CaDiCaL_EC="CaDiCaL-1.3.0-GCC-9.3.0.eb" +##echo ">> Installing ${CaDiCaL_EC}..." +##ok_msg="${CaDiCaL_EC} installed, let's solve some problems!" +##fail_msg="Installation of ${CaDiCaL_EC} failed, that's a pity..." +##$EB ${CaDiCaL_EC} --robot +##check_exit_code $? "${ok_msg}" "${fail_msg}" ##### install CMake with custom easyblock that patches CMake when --sysroot is used ####echo ">> Install CMake with fixed easyblock to take into account --sysroot" diff --git a/build_container.sh b/build_container.sh index 4454214a0d..f621a46f3e 100755 --- a/build_container.sh +++ b/build_container.sh @@ -1,5 +1,7 @@ #!/bin/bash +env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/build_container.sh:/' + BUILD_CONTAINER="docker://ghcr.io/eessi/build-node:debian10" if [ $# -lt 2 ]; then diff --git a/eessi-2021.12.yml b/eessi-2021.12.yml index 030d53bd1b..56659b3dc2 100644 --- a/eessi-2021.12.yml +++ b/eessi-2021.12.yml @@ -1,6 +1 @@ software: - CaDiCaL: - toolchains: - GCC-9.3.0: - versions: ['1.3.0'] - diff --git a/install_software_layer.sh b/install_software_layer.sh index b045d75f90..aa427d1e10 100755 --- a/install_software_layer.sh +++ b/install_software_layer.sh @@ -1,3 +1,4 @@ #!/bin/bash +env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/install_software_layer.sh:/' export EESSI_PILOT_VERSION='2021.12' ./run_in_compat_layer_env.sh ./EESSI-pilot-install-software.sh diff --git a/run_in_compat_layer_env.sh b/run_in_compat_layer_env.sh index e93cf3b313..a6f4fb5fa1 100755 --- a/run_in_compat_layer_env.sh +++ b/run_in_compat_layer_env.sh @@ -1,4 +1,5 @@ #!/bin/bash +env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/run_in_compat_layer.sh:/' if [ -z $EESSI_PILOT_VERSION ]; then echo "ERROR: \$EESSI_PILOT_VERSION must be set!" >&2 exit 1 From 8415e2eecb9724359c78749c891c2cbcb418ee16 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 05:03:25 +0200 Subject: [PATCH 19/44] Added customized startprefix for retaining EASYBUILD_OPTARCH Otherwise there seems to be no other way currently to tell the EESSI install script to build for the generic architecture. --- build_container.sh | 2 +- startprefix | 87 ++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 88 insertions(+), 1 deletion(-) create mode 100755 startprefix diff --git a/build_container.sh b/build_container.sh index f621a46f3e..2757f3efe4 100755 --- a/build_container.sh +++ b/build_container.sh @@ -45,7 +45,7 @@ mkdir -p $EESSI_TMPDIR/{var-lib-cvmfs,var-run-cvmfs} export SINGULARITY_CACHEDIR=$EESSI_TMPDIR/singularity_cache # take into account that $SINGULARITY_BIND may be defined already, to bind additional paths into the build container -BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR,nessi.uiocloud.no:/etc/cvmfs/keys/nessi.uiocloud.no,nessi.uiocloud.no.conf:/etc/cvmfs/domain.d/nessi.uiocloud.no.conf,default.local:/etc/cvmfs/default.local" +BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR,nessi.uiocloud.no:/etc/cvmfs/keys/nessi.uiocloud.no,nessi.uiocloud.no.conf:/etc/cvmfs/domain.d/nessi.uiocloud.no.conf,default.local:/etc/cvmfs/default.local,startprefix:/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/startprefix" if [ -z $SINGULARITY_BIND ]; then export SINGULARITY_BIND="$BIND_PATHS" else diff --git a/startprefix b/startprefix new file mode 100755 index 0000000000..b0e2f24268 --- /dev/null +++ b/startprefix @@ -0,0 +1,87 @@ +#!/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/bin/bash +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +# Fabian Groffen -- 2007-03-10 +# Enters the prefix environment by starting a login shell from the +# prefix. The SHELL environment variable is elevated in order to make +# applications that start login shells to work, such as `screen`. + +# if you come from a substantially polluted environment (another +# Prefix), a cleanup as follows resolves most oddities I've ever seen: +# env -i HOME=$HOME TERM=$TERM USER=$USER $SHELL -l +# hence this script starts the Prefix shell like this + +if [[ ${SHELL#/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64} != ${SHELL} ]] +then + echo "You appear to be in prefix already (SHELL=${SHELL})" > /dev/stderr + exit -1 +elif [[ ${SHELL#/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64} != ${SHELL} ]] && + [[ ${EPREFIX-unset} == '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' ]] +then + echo "You appear to be in stacked prefix already (EPREFIX=${EPREFIX})" > /dev/stderr + exit -1 +fi + +# What is our prefix? +EPREFIX='/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' +BPREFIX='/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' + +# not all systems have the same location for shells, however what it +# boils down to, is that we need to know what the shell is, and then we +# can find it in the bin dir of our prefix +for SHELL in \ + "${EPREFIX}/bin/${SHELL##*/}" \ + "${BPREFIX}/bin/${SHELL##*/}" \ + ${SHELL##*/} +do + [[ ${SHELL} == */* && -x ${SHELL} ]] && break +done + +# check if the shell exists +if [[ ${SHELL} != */* ]] +then + echo "Failed to find the Prefix shell, this is probably" > /dev/stderr + echo "because you didn't emerge the shell ${SHELL}" > /dev/stderr + exit 1 +fi + +# set the prefix shell in the environment +export SHELL + +# give a small notice +echo "Entering Gentoo Prefix ${EPREFIX}" +# start the login shell, clean the entire environment but what's needed +RETAIN="HOME=$HOME TERM=$TERM USER=$USER SHELL=$SHELL" +# PROFILEREAD is necessary on SUSE not to wipe the env on shell start +[[ -n ${PROFILEREAD} ]] && RETAIN+=" PROFILEREAD=$PROFILEREAD" +# ssh-agent is handy to keep, of if set, inherit it +[[ -n ${SSH_AUTH_SOCK} ]] && RETAIN+=" SSH_AUTH_SOCK=$SSH_AUTH_SOCK" +# if we're on some X terminal, makes sense to inherit that too +[[ -n ${DISPLAY} ]] && RETAIN+=" DISPLAY=$DISPLAY" +if [[ -d /proc/registry ]]; then # we're on Cygwin + # crucial to Windows but cannot be restored, see + # https://cygwin.com/ml/cygwin/2019-08/msg00072.html + [[ -n ${SYSTEMDRIVE} ]] && RETAIN+=" SYSTEMDRIVE=$SYSTEMDRIVE" + # COMSPEC is to native Windows what SHELL is to *nix + [[ -n ${COMSPEC} ]] && RETAIN+=" COMSPEC=$COMSPEC" + # some Windows programs (e.g. devenv.exe) need TMP or TEMP + [[ -n ${TEMP} ]] && RETAIN+=" TEMP=$TEMP" +fi +# for creating generic software installation with the bot we need to retain EASYBUILD_OPTARCH +[[ -n ${EASYBUILD_OPTARCH} ]] && RETAIN+=" EASYBUILD_OPTARCH=$EASYBUILD_OPTARCH" +# do it! +if [[ ${SHELL#${EPREFIX}} != ${SHELL} ]] ; then + '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/usr/bin/env' -i $RETAIN $SHELL -l +elif [[ ' bash ' == *" ${SHELL##*/} "* ]] ; then + # shell coming from different prefix would load it's own + # etc/profile upon -l, so we have to override + '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/usr/bin/env' -i ${RETAIN} "${SHELL}" --rcfile "${EPREFIX}"/etc/prefix-stack.bash_login -i +else + echo "Only bash is supported with stacked Prefix (you have ${SHELL##*/}), sorry!" > /dev/stderr + exit 1 +fi +# and leave a message when we exit... the shell might return non-zero +# without having real problems, so don't send alarming messages about +# that +echo "Leaving Gentoo Prefix with exit status $?" From 0ce75aa4d7b976fa4fedea4a0b8469604e1e92de Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 05:20:25 +0200 Subject: [PATCH 20/44] Revert "Added customized startprefix for retaining EASYBUILD_OPTARCH" This reverts commit 8415e2eecb9724359c78749c891c2cbcb418ee16. Reverting because it didn't work. --- build_container.sh | 2 +- startprefix | 87 ---------------------------------------------- 2 files changed, 1 insertion(+), 88 deletions(-) delete mode 100755 startprefix diff --git a/build_container.sh b/build_container.sh index 2757f3efe4..f621a46f3e 100755 --- a/build_container.sh +++ b/build_container.sh @@ -45,7 +45,7 @@ mkdir -p $EESSI_TMPDIR/{var-lib-cvmfs,var-run-cvmfs} export SINGULARITY_CACHEDIR=$EESSI_TMPDIR/singularity_cache # take into account that $SINGULARITY_BIND may be defined already, to bind additional paths into the build container -BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR,nessi.uiocloud.no:/etc/cvmfs/keys/nessi.uiocloud.no,nessi.uiocloud.no.conf:/etc/cvmfs/domain.d/nessi.uiocloud.no.conf,default.local:/etc/cvmfs/default.local,startprefix:/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/startprefix" +BIND_PATHS="$EESSI_TMPDIR/var-run-cvmfs:/var/run/cvmfs,$EESSI_TMPDIR/var-lib-cvmfs:/var/lib/cvmfs,$EESSI_TMPDIR,nessi.uiocloud.no:/etc/cvmfs/keys/nessi.uiocloud.no,nessi.uiocloud.no.conf:/etc/cvmfs/domain.d/nessi.uiocloud.no.conf,default.local:/etc/cvmfs/default.local" if [ -z $SINGULARITY_BIND ]; then export SINGULARITY_BIND="$BIND_PATHS" else diff --git a/startprefix b/startprefix deleted file mode 100755 index b0e2f24268..0000000000 --- a/startprefix +++ /dev/null @@ -1,87 +0,0 @@ -#!/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/bin/bash -# Copyright 1999-2019 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -# Fabian Groffen -- 2007-03-10 -# Enters the prefix environment by starting a login shell from the -# prefix. The SHELL environment variable is elevated in order to make -# applications that start login shells to work, such as `screen`. - -# if you come from a substantially polluted environment (another -# Prefix), a cleanup as follows resolves most oddities I've ever seen: -# env -i HOME=$HOME TERM=$TERM USER=$USER $SHELL -l -# hence this script starts the Prefix shell like this - -if [[ ${SHELL#/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64} != ${SHELL} ]] -then - echo "You appear to be in prefix already (SHELL=${SHELL})" > /dev/stderr - exit -1 -elif [[ ${SHELL#/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64} != ${SHELL} ]] && - [[ ${EPREFIX-unset} == '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' ]] -then - echo "You appear to be in stacked prefix already (EPREFIX=${EPREFIX})" > /dev/stderr - exit -1 -fi - -# What is our prefix? -EPREFIX='/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' -BPREFIX='/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64' - -# not all systems have the same location for shells, however what it -# boils down to, is that we need to know what the shell is, and then we -# can find it in the bin dir of our prefix -for SHELL in \ - "${EPREFIX}/bin/${SHELL##*/}" \ - "${BPREFIX}/bin/${SHELL##*/}" \ - ${SHELL##*/} -do - [[ ${SHELL} == */* && -x ${SHELL} ]] && break -done - -# check if the shell exists -if [[ ${SHELL} != */* ]] -then - echo "Failed to find the Prefix shell, this is probably" > /dev/stderr - echo "because you didn't emerge the shell ${SHELL}" > /dev/stderr - exit 1 -fi - -# set the prefix shell in the environment -export SHELL - -# give a small notice -echo "Entering Gentoo Prefix ${EPREFIX}" -# start the login shell, clean the entire environment but what's needed -RETAIN="HOME=$HOME TERM=$TERM USER=$USER SHELL=$SHELL" -# PROFILEREAD is necessary on SUSE not to wipe the env on shell start -[[ -n ${PROFILEREAD} ]] && RETAIN+=" PROFILEREAD=$PROFILEREAD" -# ssh-agent is handy to keep, of if set, inherit it -[[ -n ${SSH_AUTH_SOCK} ]] && RETAIN+=" SSH_AUTH_SOCK=$SSH_AUTH_SOCK" -# if we're on some X terminal, makes sense to inherit that too -[[ -n ${DISPLAY} ]] && RETAIN+=" DISPLAY=$DISPLAY" -if [[ -d /proc/registry ]]; then # we're on Cygwin - # crucial to Windows but cannot be restored, see - # https://cygwin.com/ml/cygwin/2019-08/msg00072.html - [[ -n ${SYSTEMDRIVE} ]] && RETAIN+=" SYSTEMDRIVE=$SYSTEMDRIVE" - # COMSPEC is to native Windows what SHELL is to *nix - [[ -n ${COMSPEC} ]] && RETAIN+=" COMSPEC=$COMSPEC" - # some Windows programs (e.g. devenv.exe) need TMP or TEMP - [[ -n ${TEMP} ]] && RETAIN+=" TEMP=$TEMP" -fi -# for creating generic software installation with the bot we need to retain EASYBUILD_OPTARCH -[[ -n ${EASYBUILD_OPTARCH} ]] && RETAIN+=" EASYBUILD_OPTARCH=$EASYBUILD_OPTARCH" -# do it! -if [[ ${SHELL#${EPREFIX}} != ${SHELL} ]] ; then - '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/usr/bin/env' -i $RETAIN $SHELL -l -elif [[ ' bash ' == *" ${SHELL##*/} "* ]] ; then - # shell coming from different prefix would load it's own - # etc/profile upon -l, so we have to override - '/cvmfs/pilot.nessi.uiocloud.no/versions/2021.12/compat/linux/x86_64/usr/bin/env' -i ${RETAIN} "${SHELL}" --rcfile "${EPREFIX}"/etc/prefix-stack.bash_login -i -else - echo "Only bash is supported with stacked Prefix (you have ${SHELL##*/}), sorry!" > /dev/stderr - exit 1 -fi -# and leave a message when we exit... the shell might return non-zero -# without having real problems, so don't send alarming messages about -# that -echo "Leaving Gentoo Prefix with exit status $?" From 8e3eca62a6145a1ba5f5e1079fbe1079838e7953 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 09:22:24 +0200 Subject: [PATCH 21/44] Adding handling of arguments `install_software_layer.sh` now passes command line arguments to `EESSI-pilot-install-software.sh` (attempt to build stack by bot for architecture `generic`). --- install_software_layer.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/install_software_layer.sh b/install_software_layer.sh index aa427d1e10..647d131a05 100755 --- a/install_software_layer.sh +++ b/install_software_layer.sh @@ -1,4 +1,5 @@ #!/bin/bash env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/install_software_layer.sh:/' +echo "install_software_layer.sh: args '$@'" export EESSI_PILOT_VERSION='2021.12' -./run_in_compat_layer_env.sh ./EESSI-pilot-install-software.sh +./run_in_compat_layer_env.sh ./EESSI-pilot-install-software.sh "$@" From fa78dae80325b40acc756f643c4c0609b214a422 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 10:08:38 +0200 Subject: [PATCH 22/44] Making create_tarball.sh aware of --generic Added a 4th parameter. If it is set to "--generic", the variable EESSI_SOFTWARE_SUBDIR_OVERRIDE will be set to EESSI_OS_TYPE/EESSI_CPU_FAMILY/generic. --- create_tarball.sh | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index 8d896f7eba..63de4e32ea 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -2,8 +2,8 @@ set -e -if [ $# -ne 3 ]; then - echo "ERROR: Usage: $0 " >&2 +if [ $# -le 3 ]; then + echo "ERROR: Usage: $0 " >&2 exit 1 fi eessi_tmpdir=$1 @@ -11,6 +11,20 @@ component=$2 basedir=$3 source init/minimal_eessi_env + +# check if 4th parameter which might be set to --generic +echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" +if [ $# -ge 4 ]; then + echo "4th parameter is: '$4'" + if [ $4 == "--generic" ]; then + EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic + echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" + else + echo "did not set EESSI_SOFTWARE_SUBDIR_OVERRIDE" + echo "still EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" + fi +fi + # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables From e5280561e55e40a8845b4fb2a619a8e5c0eb91fb Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 10:45:47 +0200 Subject: [PATCH 23/44] Adding more debug output for software override --- create_tarball.sh | 1 + init/eessi_environment_variables | 3 +++ 2 files changed, 4 insertions(+) diff --git a/create_tarball.sh b/create_tarball.sh index 63de4e32ea..14ac8e38a8 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -28,6 +28,7 @@ fi # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables + echo "after source init/eessi_environment_variables: EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" fi cpu_arch_subdir=${EESSI_SOFTWARE_SUBDIR} diff --git a/init/eessi_environment_variables b/init/eessi_environment_variables index 199b1facc5..6e082867a5 100644 --- a/init/eessi_environment_variables +++ b/init/eessi_environment_variables @@ -23,6 +23,7 @@ echo "minimal_eessi_env: EESSI_PREFIX=${EESSI_PREFIX}= EESSI_OS_TYPE=${EESSI_OS_ if [ -d $EESSI_PREFIX ]; then echo "Found EESSI pilot repo @ $EESSI_PREFIX!" >> $output + echo "EPREFIX=${EPREFIX}" export EESSI_EPREFIX=$EPREFIX if [ -d $EESSI_EPREFIX ]; then @@ -30,6 +31,8 @@ if [ -d $EESSI_PREFIX ]; then # note: eessi_software_subdir_for_host.py will pick up value from $EESSI_SOFTWARE_SUBDIR_OVERRIDE if it's defined! export EESSI_EPREFIX_PYTHON=$EESSI_EPREFIX/usr/bin/python3 export EESSI_SOFTWARE_SUBDIR=$($EESSI_EPREFIX_PYTHON ${EESSI_INIT_DIR_PATH}/eessi_software_subdir_for_host.py $EESSI_PREFIX) + echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_SOFTWARE_SUBDIR_OVERRIDE}" + echo "determining subdir with .py script: $($EESSI_EPREFIX_PYTHON ${EESSI_INIT_DIR_PATH}/eessi_software_subdir_for_host.py $EESSI_PREFIX)" if [ ! -z $EESSI_SOFTWARE_SUBDIR ]; then echo "Using ${EESSI_SOFTWARE_SUBDIR} as software subdirectory." >> $output From 67c154b70f51bc20748f6a2edb76bc348334e310 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 10:57:43 +0200 Subject: [PATCH 24/44] Export override variable Otherwise it would not be visible to the .py script determining the target. --- create_tarball.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/create_tarball.sh b/create_tarball.sh index 14ac8e38a8..5d09183b0a 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -17,7 +17,7 @@ echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" if [ $# -ge 4 ]; then echo "4th parameter is: '$4'" if [ $4 == "--generic" ]; then - EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic + export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" else echo "did not set EESSI_SOFTWARE_SUBDIR_OVERRIDE" From ffc6d9e40809aabf18ccec0254566f7df3eebb5a Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 11:02:28 +0200 Subject: [PATCH 25/44] Removing OS_TYPE from orverride variable --- create_tarball.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/create_tarball.sh b/create_tarball.sh index 5d09183b0a..cb9f73af52 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -17,7 +17,8 @@ echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" if [ $# -ge 4 ]; then echo "4th parameter is: '$4'" if [ $4 == "--generic" ]; then - export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic + #export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic + export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" else echo "did not set EESSI_SOFTWARE_SUBDIR_OVERRIDE" From 9726a3fec1f2a20d2aea4dcaf128b9d680cd90ea Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 11:27:22 +0200 Subject: [PATCH 26/44] Put comparison operands in double quotes --- create_tarball.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index cb9f73af52..a7b7cc9cc4 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -2,7 +2,7 @@ set -e -if [ $# -le 3 ]; then +if [ "$#" -le 3 ]; then echo "ERROR: Usage: $0 " >&2 exit 1 fi @@ -14,10 +14,9 @@ source init/minimal_eessi_env # check if 4th parameter which might be set to --generic echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" -if [ $# -ge 4 ]; then +if [ "$#" -ge 4 ]; then echo "4th parameter is: '$4'" - if [ $4 == "--generic" ]; then - #export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/generic + if [ "$4" == "--generic" ]; then export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" else From e858cfb358beef477257899156a0fe9c38733ec1 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 11:34:05 +0200 Subject: [PATCH 27/44] Fixing bug in comparison: -le vs -lt --- create_tarball.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index a7b7cc9cc4..e47d260c07 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -2,7 +2,7 @@ set -e -if [ "$#" -le 3 ]; then +if [ $# -lt 3 ]; then echo "ERROR: Usage: $0 " >&2 exit 1 fi @@ -14,7 +14,7 @@ source init/minimal_eessi_env # check if 4th parameter which might be set to --generic echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" -if [ "$#" -ge 4 ]; then +if [ $# -ge 4 ]; then echo "4th parameter is: '$4'" if [ "$4" == "--generic" ]; then export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic From 57d6587a992444773107f927994e9f2a8a962f09 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 12:58:46 +0200 Subject: [PATCH 28/44] Polished code Removed unneccessary code (echos etc) --- create_tarball.sh | 15 +++------------ install_software_layer.sh | 2 -- 2 files changed, 3 insertions(+), 14 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index e47d260c07..54d243c122 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -12,23 +12,14 @@ basedir=$3 source init/minimal_eessi_env -# check if 4th parameter which might be set to --generic -echo "EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" -if [ $# -ge 4 ]; then - echo "4th parameter is: '$4'" - if [ "$4" == "--generic" ]; then - export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic - echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" - else - echo "did not set EESSI_SOFTWARE_SUBDIR_OVERRIDE" - echo "still EESSI_SOFTWARE_SUBDIR_OVERRIDE='${EESSI_SOFTWARE_SUBDIR_OVERRIDE}'" - fi +# check if 4th parameter is provided and set to --generic +if [ $# -ge 4 -a "$4" == "--generic" ]; then + export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic fi # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables - echo "after source init/eessi_environment_variables: EESSI_SOFTWARE_SUBDIR='${EESSI_SOFTWARE_SUBDIR}'" fi cpu_arch_subdir=${EESSI_SOFTWARE_SUBDIR} diff --git a/install_software_layer.sh b/install_software_layer.sh index 647d131a05..e0b2f785d5 100755 --- a/install_software_layer.sh +++ b/install_software_layer.sh @@ -1,5 +1,3 @@ #!/bin/bash -env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/install_software_layer.sh:/' -echo "install_software_layer.sh: args '$@'" export EESSI_PILOT_VERSION='2021.12' ./run_in_compat_layer_env.sh ./EESSI-pilot-install-software.sh "$@" From 8f9a8c199e4a0fd33c4365d1598debfe41904dbe Mon Sep 17 00:00:00 2001 From: poksumdo Date: Wed, 17 Aug 2022 13:31:22 +0200 Subject: [PATCH 29/44] Removed debugging output --- EESSI-pilot-install-software.sh | 2 -- init/eessi_environment_variables | 3 --- 2 files changed, 5 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 7260c9afa3..b4f4caf5f2 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -3,8 +3,6 @@ # Script to install EESSI pilot software stack (version 2021.12) # -env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/EESSI-pilot-install-software.sh:/' - TOPDIR=$(dirname $(realpath $0)) source $TOPDIR/utils.sh diff --git a/init/eessi_environment_variables b/init/eessi_environment_variables index 6e082867a5..199b1facc5 100644 --- a/init/eessi_environment_variables +++ b/init/eessi_environment_variables @@ -23,7 +23,6 @@ echo "minimal_eessi_env: EESSI_PREFIX=${EESSI_PREFIX}= EESSI_OS_TYPE=${EESSI_OS_ if [ -d $EESSI_PREFIX ]; then echo "Found EESSI pilot repo @ $EESSI_PREFIX!" >> $output - echo "EPREFIX=${EPREFIX}" export EESSI_EPREFIX=$EPREFIX if [ -d $EESSI_EPREFIX ]; then @@ -31,8 +30,6 @@ if [ -d $EESSI_PREFIX ]; then # note: eessi_software_subdir_for_host.py will pick up value from $EESSI_SOFTWARE_SUBDIR_OVERRIDE if it's defined! export EESSI_EPREFIX_PYTHON=$EESSI_EPREFIX/usr/bin/python3 export EESSI_SOFTWARE_SUBDIR=$($EESSI_EPREFIX_PYTHON ${EESSI_INIT_DIR_PATH}/eessi_software_subdir_for_host.py $EESSI_PREFIX) - echo "EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_SOFTWARE_SUBDIR_OVERRIDE}" - echo "determining subdir with .py script: $($EESSI_EPREFIX_PYTHON ${EESSI_INIT_DIR_PATH}/eessi_software_subdir_for_host.py $EESSI_PREFIX)" if [ ! -z $EESSI_SOFTWARE_SUBDIR ]; then echo "Using ${EESSI_SOFTWARE_SUBDIR} as software subdirectory." >> $output From 0af6437b6a9e47f935349c73872dcaca32765d33 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 12:14:07 +0200 Subject: [PATCH 30/44] Adding a bit more debug output --- EESSI-pilot-install-software.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index b4f4caf5f2..eb44defffb 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -15,6 +15,7 @@ else fi TMPDIR=$(mktemp -d) +echo "TMPDIR=${TMPDIR}; size=$(df -h ${TMPDIR})" echo ">> Setting up environment..." @@ -98,10 +99,12 @@ else echo_yellow ">> No EasyBuild module yet, installing it..." EB_TMPDIR=${TMPDIR}/ebtmp - echo ">> Temporary installation (in ${EB_TMPDIR})..." + echo ">> Temporary installation (in ${EB_TMPDIR}, $(df -h ${EB_TMPDIR}))..." pip_install_out=${TMPDIR}/pip_install.out pip3 install --prefix $EB_TMPDIR easybuild &> ${pip_install_out} + tail ${pip_install_out} + echo ">> Final installation in ${EASYBUILD_INSTALLPATH}..." export PATH=${EB_TMPDIR}/bin:$PATH export PYTHONPATH=$(ls -d ${EB_TMPDIR}/lib/python*/site-packages):$PYTHONPATH From 5dce8d4c15c5f27e3696e2fac3f7959179826164 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 12:31:20 +0200 Subject: [PATCH 31/44] More debug output (http*) --- EESSI-pilot-install-software.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index eb44defffb..3c7abdd06c 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -17,6 +17,9 @@ fi TMPDIR=$(mktemp -d) echo "TMPDIR=${TMPDIR}; size=$(df -h ${TMPDIR})" +# are proxies configured +env | grep -i http + echo ">> Setting up environment..." source $TOPDIR/init/minimal_eessi_env From b4f78b46c18fb15ae733382016ca305130f88c79 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 14:10:17 +0200 Subject: [PATCH 32/44] More command line arguments Added command line arguments for setting http(s)_proxy. Added parsing of command line arguments. --- EESSI-pilot-install-software.sh | 48 +++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 3c7abdd06c..eb00e350d2 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -1,7 +1,50 @@ #!/bin/bash # # Script to install EESSI pilot software stack (version 2021.12) -# + +# see example parsing of command line arguments at +# https://wiki.bash-hackers.org/scripting/posparams#using_a_while_loop + +display_help() { + echo "usage: $0 [OPTIONS]" + echo " -g | --generic - instructs script to build for generic architecture target" + echo " -h | --help - display this usage information" + echo " -x | --http_proxy URL - provides URL for the environment variable http_proxy" + echo " -y | --https_proxy URL - provides URL for the environment variable https_proxy" +} + +while : +do + case "$1" in + -g | --generic) + EASYBUILD_OPTARCH="GENERIC" + shift + ;; + -h | --help) + display_help # Call your function + # no shifting needed here, we're done. + exit 0 + ;; + -x | --http_proxy) + export http_proxy="$2" + shift 2 + ;; + -y | --https_proxy) + export https_proxy="$2" + shift 2 + ;; + --) # End of all options + shift + break; + -*) + echo "Error: Unknown option: $1" >&2 + exit 1 + ;; + *) # No more options + break + ;; + esac +done TOPDIR=$(dirname $(realpath $0)) @@ -18,6 +61,7 @@ TMPDIR=$(mktemp -d) echo "TMPDIR=${TMPDIR}; size=$(df -h ${TMPDIR})" # are proxies configured +echo "are proxies defined via http*?" env | grep -i http echo ">> Setting up environment..." @@ -43,7 +87,7 @@ export PYTHONPYCACHEPREFIX=$TMPDIR/pycache DETECTION_PARAMETERS='' GENERIC=0 EB='eb' -if [[ "$1" == "--generic" || "$EASYBUILD_OPTARCH" == "GENERIC" ]]; then +if [[ "$EASYBUILD_OPTARCH" == "GENERIC" ]]; then echo_yellow ">> GENERIC build requested, taking appropriate measures!" DETECTION_PARAMETERS="$DETECTION_PARAMETERS --generic" GENERIC=1 From 6af6fb1b881e43368d8e7c879418da1f2e0068a8 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 14:11:25 +0200 Subject: [PATCH 33/44] Added a bit more debug output --- run_in_compat_layer_env.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/run_in_compat_layer_env.sh b/run_in_compat_layer_env.sh index a6f4fb5fa1..f05d14caae 100755 --- a/run_in_compat_layer_env.sh +++ b/run_in_compat_layer_env.sh @@ -1,4 +1,5 @@ #!/bin/bash +echo "is env var EASYBUILD_OPTARCH set?" env | grep -i EASYBUILD_OPTARCH | sed -e 's/^/run_in_compat_layer.sh:/' if [ -z $EESSI_PILOT_VERSION ]; then echo "ERROR: \$EESSI_PILOT_VERSION must be set!" >&2 From d04bf1571c011fb199ba58d04b0d03c2fa121899 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 14:57:04 +0200 Subject: [PATCH 34/44] Improved command line parsing --- EESSI-pilot-install-software.sh | 64 +++++++++++++++++---------------- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index eb00e350d2..e74c433377 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -4,6 +4,7 @@ # see example parsing of command line arguments at # https://wiki.bash-hackers.org/scripting/posparams#using_a_while_loop +# https://stackoverflow.com/questions/192249/how-do-i-parse-command-line-arguments-in-bash display_help() { echo "usage: $0 [OPTIONS]" @@ -13,39 +14,40 @@ display_help() { echo " -y | --https_proxy URL - provides URL for the environment variable https_proxy" } -while : -do - case "$1" in - -g | --generic) - EASYBUILD_OPTARCH="GENERIC" - shift - ;; - -h | --help) - display_help # Call your function - # no shifting needed here, we're done. - exit 0 - ;; - -x | --http_proxy) - export http_proxy="$2" - shift 2 - ;; - -y | --https_proxy) - export https_proxy="$2" - shift 2 - ;; - --) # End of all options - shift - break; - -*) - echo "Error: Unknown option: $1" >&2 - exit 1 - ;; - *) # No more options - break - ;; - esac +POSITIONAL_ARGS=() + +while [[ $# -gt 0 ]]; do + case $1 in + -g|--generic) + EASYBUILD_OPTARCH="GENERIC" + shift + ;; + -h|--help) + display_help # Call your function + # no shifting needed here, we're done. + exit 0 + ;; + -x|--http-proxy) + export http_proxy="$2" + shift 2 + ;; + -y|--https-proxy) + export https_proxy="$2" + shift 2 + ;; + -*|--*) + echo "Error: Unknown option: $1" >&2 + exit 1 + ;; + *) # No more options + POSITIONAL_ARGS+=("$1") # save positional arg + shift + ;; + esac done +set -- "${POSITIONAL_ARGS[@]}" + TOPDIR=$(dirname $(realpath $0)) source $TOPDIR/utils.sh From 602cef6565d55cdd85b3cd6d964807ad982f28c0 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Tue, 23 Aug 2022 15:10:14 +0200 Subject: [PATCH 35/44] Adding more debug output Verifying if pypi.org can be accessed. --- EESSI-pilot-install-software.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index e74c433377..93fe2c9d01 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -147,6 +147,8 @@ if [[ $? -eq 0 ]]; then else echo_yellow ">> No EasyBuild module yet, installing it..." + curl -I https://pypi.org/simple/easybuild/ + EB_TMPDIR=${TMPDIR}/ebtmp echo ">> Temporary installation (in ${EB_TMPDIR}, $(df -h ${EB_TMPDIR}))..." pip_install_out=${TMPDIR}/pip_install.out From beeb92711c17056b4fcd13f9ee47f833818318c3 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Wed, 31 Aug 2022 04:01:20 +0200 Subject: [PATCH 36/44] Attempt to fix patch issue with trz42/PR11 Started from commit that was patchable and added changes that were made to poksumdo/software-layer/add-Java-11.0.2-generic-nessi. --- EESSI-pilot-install-software.sh | 20 ++++++++++---------- build_container.sh | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 93fe2c9d01..809dc36b57 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -204,16 +204,16 @@ fail_msg="Failed to install Java, woopsie..." $EB Java-11.eb --robot --include-easyblocks-from-pr 2557 check_exit_code $? "${ok_msg}" "${fail_msg}" -### install GCC for foss/2020a -##export GCC_EC="GCC-9.3.0.eb" -##echo ">> Starting slow with ${GCC_EC}..." -##ok_msg="${GCC_EC} installed, yippy! Off to a good start..." -##fail_msg="Installation of ${GCC_EC} failed!" -### pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, -### which includes patch to fix build of GCC 9.3 when recent kernel headers are in place -##$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb -##check_exit_code $? "${ok_msg}" "${fail_msg}" -## +## install GCC for foss/2020a +#export GCC_EC="GCC-9.3.0.eb" +#echo ">> Starting slow with ${GCC_EC}..." +#ok_msg="${GCC_EC} installed, yippy! Off to a good start..." +#fail_msg="Installation of ${GCC_EC} failed!" +## pull in easyconfig from https://github.com/easybuilders/easybuild-easyconfigs/pull/14453, +## which includes patch to fix build of GCC 9.3 when recent kernel headers are in place +#$EB ${GCC_EC} --robot --from-pr 14453 GCCcore-9.3.0.eb +#check_exit_code $? "${ok_msg}" "${fail_msg}" + ##export CaDiCaL_EC="CaDiCaL-1.3.0-GCC-9.3.0.eb" ##echo ">> Installing ${CaDiCaL_EC}..." ##ok_msg="${CaDiCaL_EC} installed, let's solve some problems!" diff --git a/build_container.sh b/build_container.sh index f621a46f3e..4ec194b91c 100755 --- a/build_container.sh +++ b/build_container.sh @@ -28,7 +28,7 @@ if [ $? -eq 0 ]; then attr -s test -V test $testfile > /dev/null if [ $? -ne 0 ]; then echo "ERROR: $EESSI_TMPDIR does not support extended attributes!" >&2 - exit 2 + #exit 2 else rm $testfile fi From 6090cfe309271be4a48b918dc7d5ef401048107f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20R=C3=B6blitz?= Date: Fri, 26 Aug 2022 18:13:23 +0200 Subject: [PATCH 37/44] Improved handling of command line parameters --- create_tarball.sh | 67 +++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 62 insertions(+), 5 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index 54d243c122..c858d535a9 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -10,13 +10,70 @@ eessi_tmpdir=$1 component=$2 basedir=$3 -source init/minimal_eessi_env - -# check if 4th parameter is provided and set to --generic -if [ $# -ge 4 -a "$4" == "--generic" ]; then - export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic +# see example parsing of command line arguments at +# https://wiki.bash-hackers.org/scripting/posparams#using_a_while_loop +# https://stackoverflow.com/questions/192249/how-do-i-parse-command-line-arguments-in-bash + +display_help() { + echo "usage: $0 [OPTIONS]" + echo " OPTIONS" + echo " -g | --generic - instructs script to tar files of generic architecture target" + echo " -h | --help - display this usage information" + echo " -x | --http_proxy URL - provides URL for the environment variable http_proxy" + echo " -y | --https_proxy URL - provides URL for the environment variable https_proxy" +} + +POSITIONAL_ARGS=() + +while [[ $# -gt 0 ]]; do + case $1 in + -g|--generic) + EASYBUILD_OPTARCH="GENERIC" + shift + ;; + -h|--help) + display_help # Call your function + # no shifting needed here, we're done. + exit 0 + ;; + -x|--http-proxy) + export http_proxy="$2" + shift 2 + ;; + -y|--https-proxy) + export https_proxy="$2" + shift 2 + ;; + -*|--*) + echo "Error: Unknown option: $1" >&2 + exit 1 + ;; + *) # No more options + POSITIONAL_ARGS+=("$1") # save positional arg + shift + ;; + esac +done + +set -- "${POSITIONAL_ARGS[@]}" + +TOPDIR=$(dirname $(realpath $0)) + +source $TOPDIR/utils.sh + +DETECTION_PARAMETERS='' +GENERIC=0 +if [[ "$EASYBUILD_OPTARCH" == "GENERIC" ]]; then + echo_yellow ">> Tar'ing GENERIC build, taking appropriate measures!" + DETECTION_PARAMETERS="$DETECTION_PARAMETERS --generic" + GENERIC=1 fi +echo ">> Determining software subdirectory to use for target..." +export EESSI_SOFTWARE_SUBDIR_OVERRIDE=$(python3 $TOPDIR/eessi_software_subdir.py $DETECTION_PARAMETERS) + +source init/minimal_eessi_env + # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables From 4242150a7e542035d5c8b6860ff161fcf8a2c59e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20R=C3=B6blitz?= Date: Sat, 27 Aug 2022 07:31:03 +0200 Subject: [PATCH 38/44] Fixed order of scripts to set up env vars --- create_tarball.sh | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index c858d535a9..4a2f05403e 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -61,19 +61,20 @@ TOPDIR=$(dirname $(realpath $0)) source $TOPDIR/utils.sh -DETECTION_PARAMETERS='' -GENERIC=0 +# need to source minimal_eessi_env early to have EESSI_CPU_FAMILY defined +source $TOPDIR/init/minimal_eessi_env + +if [ -d $EESSI_CVMFS_REPO ]; then + echo_green "$EESSI_CVMFS_REPO available, OK!" +else + fatal_error "$EESSI_CVMFS_REPO is not available!" +fi + if [[ "$EASYBUILD_OPTARCH" == "GENERIC" ]]; then echo_yellow ">> Tar'ing GENERIC build, taking appropriate measures!" - DETECTION_PARAMETERS="$DETECTION_PARAMETERS --generic" - GENERIC=1 + export EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_CPU_FAMILY}/generic fi -echo ">> Determining software subdirectory to use for target..." -export EESSI_SOFTWARE_SUBDIR_OVERRIDE=$(python3 $TOPDIR/eessi_software_subdir.py $DETECTION_PARAMETERS) - -source init/minimal_eessi_env - # if EESSI_SOFTWARE_SUBDIR not set get it (note can be overridden by EESSI_SOFTWARE_SUBDIR_OVERRIDE) if [ -z $EESSI_SOFTWARE_SUBDIR ]; then source init/eessi_environment_variables From 4bd3af789d4987684c430375b2bd31b3284828e0 Mon Sep 17 00:00:00 2001 From: poksumdo Date: Fri, 2 Sep 2022 05:41:01 +0200 Subject: [PATCH 39/44] Removed --http(s)-proxy parameters --- create_tarball.sh | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index 4a2f05403e..6cbbe0795b 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -19,8 +19,6 @@ display_help() { echo " OPTIONS" echo " -g | --generic - instructs script to tar files of generic architecture target" echo " -h | --help - display this usage information" - echo " -x | --http_proxy URL - provides URL for the environment variable http_proxy" - echo " -y | --https_proxy URL - provides URL for the environment variable https_proxy" } POSITIONAL_ARGS=() @@ -36,14 +34,6 @@ while [[ $# -gt 0 ]]; do # no shifting needed here, we're done. exit 0 ;; - -x|--http-proxy) - export http_proxy="$2" - shift 2 - ;; - -y|--https-proxy) - export https_proxy="$2" - shift 2 - ;; -*|--*) echo "Error: Unknown option: $1" >&2 exit 1 From 4d431fb7186a47016c0385cd4525dfb83c84859a Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Tue, 6 Sep 2022 14:22:34 +0200 Subject: [PATCH 40/44] Create ebtmp directory explicitly --- EESSI-pilot-install-software.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 0c832fdee9..81087be011 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -98,6 +98,7 @@ else echo_yellow ">> No EasyBuild module yet, installing it..." EB_TMPDIR=${TMPDIR}/ebtmp + mkdir -p $EB_TMPDIR echo ">> Temporary installation (in ${EB_TMPDIR})..." pip_install_out=${TMPDIR}/pip_install.out pip3 install --prefix $EB_TMPDIR easybuild &> ${pip_install_out} From 60246e842b543c4bcad535bf286a96154dc7fa0c Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Tue, 6 Sep 2022 14:25:15 +0200 Subject: [PATCH 41/44] Last commit was to wrong branch --- EESSI-pilot-install-software.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 0c832fdee9..81087be011 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -98,6 +98,7 @@ else echo_yellow ">> No EasyBuild module yet, installing it..." EB_TMPDIR=${TMPDIR}/ebtmp + mkdir -p $EB_TMPDIR echo ">> Temporary installation (in ${EB_TMPDIR})..." pip_install_out=${TMPDIR}/pip_install.out pip3 install --prefix $EB_TMPDIR easybuild &> ${pip_install_out} From 527a3bf42017c7b82b837fa7de0f5ac46633c8d5 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Tue, 6 Sep 2022 14:29:33 +0200 Subject: [PATCH 42/44] Create $EB_TMPDIR explicitly --- EESSI-pilot-install-software.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/EESSI-pilot-install-software.sh b/EESSI-pilot-install-software.sh index 809dc36b57..d618d07579 100755 --- a/EESSI-pilot-install-software.sh +++ b/EESSI-pilot-install-software.sh @@ -150,6 +150,7 @@ else curl -I https://pypi.org/simple/easybuild/ EB_TMPDIR=${TMPDIR}/ebtmp + mkdir -p $EB_TMPDIR echo ">> Temporary installation (in ${EB_TMPDIR}, $(df -h ${EB_TMPDIR}))..." pip_install_out=${TMPDIR}/pip_install.out pip3 install --prefix $EB_TMPDIR easybuild &> ${pip_install_out} From 7eba3bf6c742ef7972bd271875f8bb4bd5973593 Mon Sep 17 00:00:00 2001 From: Kenneth Hoste Date: Sun, 15 Jan 2023 07:52:33 +0100 Subject: [PATCH 43/44] always exclude '.wh.*' files when creating tarball in overlay --- create_tarball.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/create_tarball.sh b/create_tarball.sh index 619d6ea2e1..f2643ccfc5 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -43,13 +43,13 @@ if [ -d ${pilot_version}/software/${os}/${cpu_arch_subdir}/.lmod ]; then fi if [ -d ${pilot_version}/software/${os}/${cpu_arch_subdir}/modules ]; then # module files - find ${pilot_version}/software/${os}/${cpu_arch_subdir}/modules -type f >> ${files_list} + find ${pilot_version}/software/${os}/${cpu_arch_subdir}/modules -type f | grep -v '/\.wh\.' >> ${files_list} # module symlinks - find ${pilot_version}/software/${os}/${cpu_arch_subdir}/modules -type l >> ${files_list} + find ${pilot_version}/software/${os}/${cpu_arch_subdir}/modules -type l | grep -v '/\.wh\.' >> ${files_list} fi if [ -d ${pilot_version}/software/${os}/${cpu_arch_subdir}/software ]; then # installation directories - ls -d ${pilot_version}/software/${os}/${cpu_arch_subdir}/software/*/* >> ${files_list} + ls -d ${pilot_version}/software/${os}/${cpu_arch_subdir}/software/*/* | grep -v '/\.wh\.' >> ${files_list} fi topdir=${cvmfs_repo}/versions/ From 724ffe489918b66455f9727c2dd6ce5598c86d45 Mon Sep 17 00:00:00 2001 From: Thomas Roeblitz Date: Sun, 15 Jan 2023 12:46:05 +0100 Subject: [PATCH 44/44] Changed nessi to eessi, removed unneeded files --- create_tarball.sh | 2 +- init/minimal_eessi_env | 2 +- nessi.uiocloud.no.conf | 4 ---- nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub | 9 --------- run_in_compat_layer_env.sh | 2 +- 5 files changed, 3 insertions(+), 16 deletions(-) delete mode 100644 nessi.uiocloud.no.conf delete mode 100644 nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub diff --git a/create_tarball.sh b/create_tarball.sh index a428000fea..342c5f03b8 100755 --- a/create_tarball.sh +++ b/create_tarball.sh @@ -81,7 +81,7 @@ tmpdir=`mktemp -d` echo ">> tmpdir: $tmpdir" os="linux" -cvmfs_repo="/cvmfs/pilot.nessi.uiocloud.no" +cvmfs_repo="/cvmfs/pilot.eessi-hpc.org" software_dir="${cvmfs_repo}/versions/${pilot_version}/software/${os}/${cpu_arch_subdir}" if [ ! -d ${software_dir} ]; then diff --git a/init/minimal_eessi_env b/init/minimal_eessi_env index 78a60e192e..39478d5c4c 100644 --- a/init/minimal_eessi_env +++ b/init/minimal_eessi_env @@ -1,6 +1,6 @@ # define minimal EESSI environment, without relying on external scripts -export EESSI_CVMFS_REPO="/cvmfs/pilot.nessi.uiocloud.no" +export EESSI_CVMFS_REPO="/cvmfs/pilot.eessi-hpc.org" export EESSI_PILOT_VERSION="${EESSI_PILOT_VERSION_OVERRIDE:=2021.12}" export EESSI_PREFIX=$EESSI_CVMFS_REPO/versions/$EESSI_PILOT_VERSION diff --git a/nessi.uiocloud.no.conf b/nessi.uiocloud.no.conf deleted file mode 100644 index 788e9b4784..0000000000 --- a/nessi.uiocloud.no.conf +++ /dev/null @@ -1,4 +0,0 @@ -## This file is maintained by Ansible - CHANGES WILL BE OVERWRITTEN -CVMFS_SERVER_URL="http://eessi-bot-devel_stratum1-0.nessi.uiocloud.no/cvmfs/@fqrn@" -CVMFS_KEYS_DIR=/etc/cvmfs/keys/nessi.uiocloud.no -CVMFS_USE_GEOAPI="yes" diff --git a/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub b/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub deleted file mode 100644 index 299f8870f8..0000000000 --- a/nessi.uiocloud.no/pilot.nessi.uiocloud.no.pub +++ /dev/null @@ -1,9 +0,0 @@ ------BEGIN PUBLIC KEY----- -MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAlPvj6cGKY/IH58gCJaQa -SqlJh1JqmNwjhwVQwUCW4VhGhKc7zX3rbDCRge4UOGNXb6/WTBipz8S3lGJ20O6m -1fE+SlujCib269oPRh2Mxd9ZYwjXB29+lVWT6s/L6QxMg4lCUQ83Kz6/sV1KycDF -myDxT0S/xgJ8n94eBCM5hxrrPoAAHChcyy403EIPhUN6zdskZq/qA83sm21PiYjq -NQhzWagLOnbJvXjKApyIfcg10P5pGCN5mROWIoerW34lpPmEgezFQpJE4re5JMzM -xQCbwYFydVPgVWJ+CmJZKG7dxirox6vbO3ukWMGUFfv9tQ+TmlZfl8fq8mHGdtIW -LQIDAQAB ------END PUBLIC KEY----- diff --git a/run_in_compat_layer_env.sh b/run_in_compat_layer_env.sh index 077276eea8..b65980007e 100755 --- a/run_in_compat_layer_env.sh +++ b/run_in_compat_layer_env.sh @@ -5,7 +5,7 @@ if [ -z $EESSI_PILOT_VERSION ]; then echo "ERROR: \$EESSI_PILOT_VERSION must be set!" >&2 exit 1 fi -EESSI_COMPAT_LAYER_DIR="/cvmfs/pilot.nessi.uiocloud.no/versions/${EESSI_PILOT_VERSION}/compat/linux/$(uname -m)" +EESSI_COMPAT_LAYER_DIR="/cvmfs/pilot.eessi-hpc.org/versions/${EESSI_PILOT_VERSION}/compat/linux/$(uname -m)" if [ ! -d ${EESSI_COMPAT_LAYER_DIR} ]; then echo "ERROR: ${EESSI_COMPAT_LAYER_DIR} does not exist!" >&2 exit 1