Skip to content

Commit e479236

Browse files
authored
Merge pull request #528 from casparvl/skip_cuda_sdk_host_injections_install
skip installation of CUDA into host_injections when testing `install_software_layer.sh` script
2 parents 3bca5b7 + c92ceb2 commit e479236

File tree

3 files changed

+13
-5
lines changed

3 files changed

+13
-5
lines changed

.github/workflows/tests_scripts.yml

+2
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,8 @@ jobs:
8383
export SINGULARITY_BIND="${PWD}:/software-layer"
8484
# force using x86_64/generic, to avoid triggering an installation from scratch
8585
sed -i "s@./EESSI-install-software.sh@\"export EESSI_SOFTWARE_SUBDIR_OVERRIDE='x86_64/generic'; ./EESSI-install-software.sh\"@g" install_software_layer.sh
86+
# skip installation of CUDA SDKs, since this is too heavy for CI
87+
sed -i "s@./EESSI-install-software.sh@./EESSI-install-software.sh --skip-cuda-install@g" install_software_layer.sh
8688
./eessi_container.sh --mode run --verbose /software-layer/install_software_layer.sh
8789
8890
- name: test create_directory_tarballs.sh script

EESSI-install-software.sh

+11-1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ display_help() {
1414
echo " -x | --http-proxy URL - provides URL for the environment variable http_proxy"
1515
echo " -y | --https-proxy URL - provides URL for the environment variable https_proxy"
1616
echo " --shared-fs-path - path to directory on shared filesystem that can be used"
17+
echo " --skip-cuda-install - disable installing a full CUDA SDK in the host_injections prefix (e.g. in CI)"
1718
}
1819

1920
function copy_build_log() {
@@ -76,6 +77,10 @@ while [[ $# -gt 0 ]]; do
7677
export shared_fs_path="${2}"
7778
shift 2
7879
;;
80+
--skip-cuda-install)
81+
export skip_cuda_install=True
82+
shift 1
83+
;;
7984
-*|--*)
8085
echo "Error: Unknown option: $1" >&2
8186
exit 1
@@ -195,7 +200,12 @@ ${TOPDIR}/install_scripts.sh --prefix ${EESSI_PREFIX}
195200
# Install full CUDA SDK in host_injections
196201
# Hardcode this for now, see if it works
197202
# TODO: We should make a nice yaml and loop over all CUDA versions in that yaml to figure out what to install
198-
${EESSI_PREFIX}/scripts/gpu_support/nvidia/install_cuda_host_injections.sh -c 12.1.1 --accept-cuda-eula
203+
# Allow skipping CUDA SDK install in e.g. CI environments
204+
if [ -z "${skip_cuda_install}" ] || [ ! "${skip_cuda_install}" ]; then
205+
${EESSI_PREFIX}/scripts/gpu_support/nvidia/install_cuda_host_injections.sh -c 12.1.1 --accept-cuda-eula
206+
else
207+
echo "Skipping installation of CUDA SDK in host_injections, since the --skip-cuda-install flag was passed"
208+
fi
199209

200210
# Install drivers in host_injections
201211
# TODO: this is commented out for now, because the script assumes that nvidia-smi is available and works;

install_apptainer_ubuntu.sh

-4
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,7 @@ set -e
55
# see https://github.com/apptainer/singularity/issues/5390#issuecomment-899111181
66
sudo apt-get install alien
77
alien --version
8-
# stick to Apptainer < 1.3.0 by downloading from EPEL 8.8 archive,
9-
# since CI workflow for testing scripts hangs/fails when using Apptainer 1.3.0
10-
# cfr. https://github.com/EESSI/software-layer/pull/514
118
epel_subdir="pub/epel/8"
12-
epel_subdir="pub/archive/epel/8.8"
139
apptainer_rpm=$(curl --silent -L https://dl.fedoraproject.org/${epel_subdir}/Everything/x86_64/Packages/a/ | grep 'apptainer-[0-9]' | sed 's/.*\(apptainer[0-9._a-z-]*.rpm\).*/\1/g')
1410
curl -OL https://dl.fedoraproject.org/${epel_subdir}/Everything/x86_64/Packages/a/${apptainer_rpm}
1511
sudo alien -d ${apptainer_rpm}

0 commit comments

Comments
 (0)