Skip to content

Commit

Permalink
Merge pull request #5 from natalie-perlin/update_gaea_c5
Browse files Browse the repository at this point in the history
correct devclean.sh, devbuild.sh and Gaea-c5 modulefiles
  • Loading branch information
RatkoVasic-NOAA authored Dec 20, 2023
2 parents 28d0643 + 0b0914f commit 7187a35
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 12 deletions.
11 changes: 9 additions & 2 deletions devbuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,11 @@ printf "PLATFORM(MACHINE)=${PLATFORM}\n" >&2
if [ "${PLATFORM}" = "wcoss2" ]; then
BUILD_CONDA="off"
fi
# Conda is not used on Gaea-c5 F2 filesystem
# it needs to be reevaluated when moved to F2 filesystem
if [ "${PLATFORM}" = "gaea-c5" ]; then
BUILD_CONDA="off"
fi

# build conda and conda environments, if requested.
if [ "${BUILD_CONDA}" = "on" ] ; then
Expand Down Expand Up @@ -244,8 +249,10 @@ if [ "${BUILD_CONDA}" = "on" ] ; then
fi

else
source ${CONDA_BUILD_DIR}/etc/profile.d/conda.sh
conda activate
if [ -d "${CONDA_BUILD_DIR}" ] ; then
source ${CONDA_BUILD_DIR}/etc/profile.d/conda.sh
conda activate
fi
fi

# Conda environment should have linux utilities to perform these tasks on macos.
Expand Down
8 changes: 5 additions & 3 deletions devclean.sh
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,12 @@ elif [ "${CLEAN}" = true ]; then
"${INSTALL_DIR}/lib64" \
"${SRW_DIR}/manage_externals/manic" \
)
for directory in $directories; do
[[ -d $directory ]] && rm -rfv $directory
done
if [ ${#directories[@]} -ge 1 ]; then
for dir in ${directories[@]}; do
[[ -d "${dir}" ]] && rm -rfv ${dir}
done
echo " "
fi
fi
# Clean all the submodules if requested. Note: Need to check out them again before attempting subsequent builds, by sourcing ${SRW_DIR}/manage_externals/checkout_externals
if [ ${INCLUDE_SUB_MODULES} == true ]; then
Expand Down
8 changes: 6 additions & 2 deletions modulefiles/tasks/gaea-c5/plot_allvars.local.lua
Original file line number Diff line number Diff line change
@@ -1,2 +1,6 @@
load("conda")
setenv("SRW_ENV", "srw_graphics")
unload("miniconda3")
unload("python")
prepend_path("MODULEPATH","/lustre/f2/dev/role.epic/contrib/C5/miniconda3/modulefiles")
load(pathJoin("miniconda3", os.getenv("miniconda3_ver") or "4.12.0"))

setenv("SRW_ENV", "regional_workflow")
8 changes: 6 additions & 2 deletions modulefiles/tasks/gaea-c5/python_srw.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
unload("miniconda3")
load("conda")
setenv("SRW_ENV", "srw_app")
unload("python")
prepend_path("MODULEPATH","/lustre/f2/dev/role.epic/contrib/C5/miniconda3/modulefiles")
load(pathJoin("miniconda3", os.getenv("miniconda3_ver") or "4.12.0"))

setenv("SRW_ENV", "workflow_tools")

load("darshan-runtime/3.4.0")
2 changes: 1 addition & 1 deletion modulefiles/tasks/gaea-c5/run_vx.local.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ if (mode() == "unload") then
unload(pathJoin("met", met_ver))
unload(pathJoin("metplus",metplus_ver))
end
load("ufs-pyenv")
load("python_srw")
5 changes: 3 additions & 2 deletions modulefiles/wflow_gaea-c5.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@ whatis([===[Loads libraries needed for running the UFS SRW App on gaea ]===])

unload("python")
load("set_pythonpath")
load("conda")
prepend_path("MODULEPATH","/lustre/f2/dev/role.epic/contrib/C5/miniconda3/modulefiles")
load(pathJoin("miniconda3", os.getenv("miniconda3_ver") or "4.12.0"))
prepend_path("MODULEPATH","/lustre/f2/dev/role.epic/contrib/C5/rocoto/modulefiles")
load("rocoto")

pushenv("MKLROOT", "/opt/intel/oneapi/mkl/2023.1.0/")

if mode() == "load" then
LmodMsgRaw([===[Please do the following to activate conda:
> conda activate srw_app
> conda activate workflow_tools
]===])
end

0 comments on commit 7187a35

Please sign in to comment.