Skip to content

Commit

Permalink
use NESSI_SITE_INSTALL when it is set
Browse files Browse the repository at this point in the history
  • Loading branch information
truib committed May 19, 2024
1 parent 0a4e36f commit 020c233
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion EESSI-extend-2023.06-easybuild.eb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,19 @@ elseif (os.getenv("NESSI_SITE_INSTALL") ~= nil) then
if ((os.getenv("NESSI_PROJECT_INSTALL") ~= nil) or (os.getenv("NESSI_USER_INSTALL") ~= nil)) then
LmodError("You cannot use NESSI_SITE_INSTALL in combination with any other NESSI_*_INSTALL environment variables")
end
easybuild_installpath = string.gsub(os.getenv("EESSI_SOFTWARE_PATH"), 'versions', 'host_injections')
site_install = os.getenv("NESSI_SITE_INSTALL")
site_modulepath = nil
if (site_install ~= nil) then
-- Check the folder exists
if not isDir(site_install) then
LmodError("The location of NESSI_SITE_INSTALL (" .. site_install .. ") does not exist or is not a folder")
end
if (mode() == "load") then
LmodMessage("Configuring for use of NESSI_SITE_INSTALL under " .. site_install)
end
easybuild_installpath = string.gsub(os.getenv("EESSI_SOFTWARE_PATH"), os.getenv("EESSI_CVMFS_REPO"), site_install)
site_modulepath = pathJoin(easybuild_installpath, 'modules', 'all')
end
else
-- Deal with user and project installs
project_install = os.getenv("NESSI_PROJECT_INSTALL")
Expand Down

0 comments on commit 020c233

Please sign in to comment.