Skip to content

[STYLE] Use full path in the zlib configuration option for PETSc for better logging #1445

[STYLE] Use full path in the zlib configuration option for PETSc for better logging

[STYLE] Use full path in the zlib configuration option for PETSc for better logging #1445

# documentation: https://help.github.com/en/articles/workflow-syntax-for-github-actions
name: Tests for EESSI-extend module functionality in software.eessi.io
on:
push:
branches: [ "main" ]
pull_request:
permissions:
contents: read # to fetch code (actions/checkout)
jobs:
basic_checks:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
include:
- eessi_version: '2023.06'
rebuild_software: "BCFtools-1.18-GCC-12.3.0.eb"
- eessi_version: '2025.06'
rebuild_software: "make-4.4.1-GCCcore-13.3.0.eb"
steps:
- name: Check out software-layer repository
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
- name: Mount EESSI CernVM-FS repository
uses: eessi/github-action-eessi@v3
with:
eessi_stack_version: ${{matrix.eessi_version}}
use_eessi_module: true
- name: Set the installation path for EESSI-extend
run: |
# Configuration item used throughout this workflow:
# adjust this to change where EESSI-extend is (re)built and picked up from
echo "MY_INSTALLATION_PATH=/tmp/easybuild" >> "$GITHUB_ENV"
- name: Install the EESSI-extend shipped with the repository
run: |
# Define a function to check the values of environment variables
# and another that checks an environment does not contain environment
# variables matching a certain pattern
source .github/workflows/scripts/test_utils.sh
# Let's start from a clean slate (unload the EESSI module)
module --force purge
check_disallowed_env_prefix EESSI_ EESSI_MODULE_STICKY
check_disallowed_env_prefix EASYBUILD_
# Load the EESSI module
module load EESSI/${{matrix.eessi_version}}
check_disallowed_env_prefix EASYBUILD_
# Load EasyBuild to install EESSI-extend
module load EasyBuild
export EASYBUILD_PREFIX=$MY_INSTALLATION_PATH
eb EESSI-extend-easybuild.eb --rebuild
module unload EasyBuild
- name: Run tests for EESSI-extend in the CVMFS install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Configure for CVMFS install
export EESSI_CVMFS_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
echo $EBROOTEESSIMINEXTEND | grep $MY_INSTALLATION_PATH || { echo "ERROR: Installed version of EESSI-extend not picked up (loaded $EBROOTEESSIMINEXTEND)" >&2; exit 1; }
# check some common EasyBuild settings
check_env_var "EASYBUILD_READ_ONLY_INSTALLDIR" "1"
check_env_var "EASYBUILD_ALLOW_LOADED_MODULES" "EasyBuild,EESSI-extend"
check_env_var "EASYBUILD_SYSROOT" "$EESSI_EPREFIX"
check_env_var "EASYBUILD_HOOKS" "/cvmfs/software.eessi.io/versions/${{matrix.eessi_version}}/init/easybuild/eb_hooks.py"
check_env_var "EASYBUILD_RPATH" "1"
check_env_var "EASYBUILD_FILTER_ENV_VARS" "LD_LIBRARY_PATH"
# check some specific ones
check_env_var "EASYBUILD_INSTALLPATH" "$EESSI_SOFTWARE_PATH"
check_env_var "EASYBUILD_UMASK" "022"
# Check some things that are EasyBuild 5+ (available in all EESSI versions so should exist)
check_env_var "EASYBUILD_STRICT_RPATH_SANITY_CHECK" "1"
check_env_var "EASYBUILD_CUDA_SANITY_CHECK_ERROR_ON_FAILED_CHECKS" "1"
check_env_var "EASYBUILD_FAIL_ON_MOD_FILES_GCCCORE" "1"
check_env_var "EASYBUILD_LOCAL_VAR_NAMING_CHECK" "error"
# Check some EESSI version specific settings
if [[ "${{ matrix.eessi_version }}" != "2023.06" ]]; then
check_env_var "EASYBUILD_PREFER_PYTHON_SEARCH_PATH" "EBPYTHONPREFIXES"
check_env_var "EASYBUILD_MODULE_SEARCH_PATH_HEADERS" "include_paths"
check_env_var "EASYBUILD_SEARCH_PATH_CPP_HEADERS" "flags"
fi
# verify the configuration is actually valid
eb --show-config
# unload and check the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_CVMFS_INSTALL
- name: Run tests for EESSI-extend in the site install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Configure for a site install
export EESSI_SITE_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# check some specific envvars
check_env_var "EASYBUILD_INSTALLPATH" "$EESSI_SITE_SOFTWARE_PATH"
check_env_var "EASYBUILD_UMASK" "022"
# verify the configuration is actually valid
eb --show-config
# unload and check the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_SITE_INSTALL
- name: Run tests for EESSI-extend in the project install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Configure for a project install
export EESSI_PROJECT_INSTALL="$MY_INSTALLATION_PATH"
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# check some specific envvars
export EXPECTED_INSTALLATION_PATH="$MY_INSTALLATION_PATH/versions/$EESSI_VERSION/software/linux/$EESSI_SOFTWARE_SUBDIR"
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH"
check_env_var "EASYBUILD_UMASK" "002"
check_env_var "EASYBUILD_GROUP_WRITABLE_INSTALLDIR" "1"
# verify the configuration is actually valid
eb --show-config
# unload and check the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_PROJECT_INSTALL
- name: Run tests for EESSI-extend in the user install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Configure for a user install
export EESSI_USER_INSTALL="$MY_INSTALLATION_PATH/$USER"
mkdir -p $EESSI_USER_INSTALL # must exist
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# check some specific envvars
export EXPECTED_INSTALLATION_PATH="$MY_INSTALLATION_PATH/$USER/versions/$EESSI_VERSION/software/linux/$EESSI_SOFTWARE_SUBDIR"
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH"
check_env_var "EASYBUILD_UMASK" "077"
# verify the configuration is actually valid
eb --show-config
# unload and check the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_USER_INSTALL
- name: Run tests for EESSI-extend in the EasyBuild hooks override scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Test overriding the EasyBuild hooks
export EESSI_EASYBUILD_HOOKS_OVERRIDE="$GITHUB_WORKSPACE/eb_hooks.py"
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
check_env_var "EASYBUILD_HOOKS" "$EESSI_EASYBUILD_HOOKS_OVERRIDE"
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_EASYBUILD_HOOKS_OVERRIDE
- name: Set accelerator target override environment variables for GPU tests
run: |
echo "STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE=accel/nvidia/cc80" >> "$GITHUB_ENV"
echo "STORED_CUDA_CC=8.0" >> "$GITHUB_ENV"
- name: Run tests for EESSI-extend with accelerators in the CVMFS install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} \
--installation-path "$MY_INSTALLATION_PATH" \
--accelerator-target "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE" \
--cuda-cc "$STORED_CUDA_CC"
# Configure for CVMFS install
export EESSI_CVMFS_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
check_env_var "EASYBUILD_INSTALLPATH" "$EESSI_SOFTWARE_PATH" # installation path should be the same unless we ask for an explicit GPU installation
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
module unload EESSI-extend
export EESSI_ACCELERATOR_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild # reload for an actual GPU installation
check_env_var "EASYBUILD_INSTALLPATH" "${EESSI_SOFTWARE_PATH}/${EESSI_ACCELERATOR_TARGET_OVERRIDE}"
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
# unload and make sure the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_ACCELERATOR_INSTALL
unset EESSI_CVMFS_INSTALL
- name: Run tests for EESSI-extend with accelerators in the site install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} \
--installation-path "$MY_INSTALLATION_PATH" \
--accelerator-target "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE" \
--cuda-cc "$STORED_CUDA_CC"
# Configure for a site install
export EESSI_SITE_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
check_env_var "EASYBUILD_INSTALLPATH" "$EESSI_SITE_SOFTWARE_PATH" # installation path should be the same unless we ask for an explicit GPU installation
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
module unload EESSI-extend
export EESSI_ACCELERATOR_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild # reload for an actual GPU installation
check_env_var "EASYBUILD_INSTALLPATH" "${EESSI_SITE_SOFTWARE_PATH}/${EESSI_ACCELERATOR_TARGET_OVERRIDE}"
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
# unload and make sure the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_ACCELERATOR_INSTALL
unset EESSI_SITE_INSTALL
- name: Run tests for EESSI-extend with accelerators in the project install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} \
--installation-path "$MY_INSTALLATION_PATH" \
--accelerator-target "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE" \
--cuda-cc "$STORED_CUDA_CC"
# Configure for a project install
export EESSI_PROJECT_INSTALL="$MY_INSTALLATION_PATH"
export EXPECTED_INSTALLATION_PATH="$MY_INSTALLATION_PATH/versions/$EESSI_VERSION/software/linux/$EESSI_SOFTWARE_SUBDIR"
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH" # installation path should be the same unless we ask for an explicit GPU installation
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
module unload EESSI-extend
export EESSI_ACCELERATOR_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild # reload for an actual GPU installation
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH" # installation path should be the same for project case
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
# unload and make sure the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_ACCELERATOR_INSTALL
unset EESSI_PROJECT_INSTALL
- name: Run tests for EESSI-extend with accelerators in the user install scenario
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} \
--installation-path "$MY_INSTALLATION_PATH" \
--accelerator-target "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE" \
--cuda-cc "$STORED_CUDA_CC"
# Configure for a user install
export EESSI_USER_INSTALL="$MY_INSTALLATION_PATH/$USER"
mkdir -p $EESSI_USER_INSTALL # must exist
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# check some specific envvars
export EXPECTED_INSTALLATION_PATH="$MY_INSTALLATION_PATH/$USER/versions/$EESSI_VERSION/software/linux/$EESSI_SOFTWARE_SUBDIR"
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH" # installation path should be the same unless we ask for an explicit GPU installation
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
module unload EESSI-extend
export EESSI_ACCELERATOR_INSTALL=1
module load EESSI-extend/${{matrix.eessi_version}}-easybuild # reload for an actual GPU installation
check_env_var "EASYBUILD_INSTALLPATH" "$EXPECTED_INSTALLATION_PATH" # installation path should be the same for user case
check_env_var "EESSI_ACCELERATOR_TARGET" "$STORED_EESSI_ACCELERATOR_TARGET_OVERRIDE"
check_env_var "EASYBUILD_CUDA_COMPUTE_CAPABILITIES" "$STORED_CUDA_CC"
# unload and make sure the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
unset EESSI_ACCELERATOR_INSTALL
unset EESSI_USER_INSTALL
- name: Dryrun tests with hooks from github and hooks from the CVMFS repo
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# Do a test rebuild (with default and local hooks)
echo "Testing a rebuild using the hooks shipped with EESSI"
eb --rebuild ${{matrix.rebuild_software}}
echo "Testing a rebuild using the hooks in the current branch"
eb --rebuild --hooks=./eb_hooks.py ${{matrix.rebuild_software}}
# unload and check the environment is clean again
module unload EESSI-extend
check_disallowed_env_prefix EASYBUILD_
- name: Verify the EESSI-extend module is consistent with the CVMFS repo
run: |
source .github/workflows/scripts/test_utils.sh
init_eessi_environment --eessi-version ${{matrix.eessi_version}} --installation-path "$MY_INSTALLATION_PATH"
# Verify we can run "module show" on the module
module show EESSI-extend/${{matrix.eessi_version}}-easybuild
# Now load it and run additional checks
module load EESSI-extend/${{matrix.eessi_version}}-easybuild
# First, check if it differs against what is currently shipped by CVMFS
diff <(grep -v '^local root = \|^-- Built with EasyBuild version' /cvmfs/software.eessi.io/versions/${{matrix.eessi_version}}/software/linux/$(uname -m)/generic/modules/all/EESSI-extend/${{matrix.eessi_version}}-easybuild.lua) <(grep -v '^local root = \|^-- Built with EasyBuild version' $MY_INSTALLATION_PATH/modules/all/EESSI-extend/${{matrix.eessi_version}}-easybuild.lua)
# Then do a consistency check in CVMFS for all architectures
.github/workflows/scripts/diff_eessi_extend.sh
# Proceed with unload and checking the environment variables
module unload EESSI-extend
# That should have unset all EasyBuild envvars (including EASYBUILD_PREFIX)
check_disallowed_env_prefix EASYBUILD_