Skip to content

Commit

Permalink
remove extra changes
Browse files Browse the repository at this point in the history
  • Loading branch information
weihuang-jedi committed Jun 10, 2024
1 parent 2cedc1b commit f1461fc
Showing 1 changed file with 8 additions and 34 deletions.
42 changes: 8 additions & 34 deletions sorc/machine-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,43 +38,17 @@ elif [[ -d /scratch1 ]] ; then
fi
target=hera
module purge
elif [[ -d /lustre && -d /ncrc ]] ; then
elif [[ -d /gpfs && -d /ncrc ]] ; then
# We are on GAEA.
if ( ! eval module help > /dev/null 2>&1 ) ; then
# We cannot simply load the module command. The GAEA
# /etc/profile modifies a number of module-related variables
# before loading the module command. Without those variables,
# the module command fails. Hence we actually have to source
# /etc/profile here.
source /etc/profile
__ms_source_etc_profile=yes
else
__ms_source_etc_profile=no
fi
module purge > /dev/null 2>&1
module purge
# clean up after purge
unset _LMFILES_
unset _LMFILES_000
unset _LMFILES_001
unset LOADEDMODULES
module load modules
if [[ -d /opt/cray/ari/modulefiles ]] ; then
module use -a /opt/cray/ari/modulefiles
fi
if [[ -d /opt/cray/pe/ari/modulefiles ]] ; then
module use -a /opt/cray/pe/ari/modulefiles
fi
if [[ -d /opt/cray/pe/craype/default/modulefiles ]] ; then
module use -a /opt/cray/pe/craype/default/modulefiles
fi
if [[ -s /etc/opt/cray/pe/admin-pe/site-config ]] ; then
source /etc/opt/cray/pe/admin-pe/site-config
fi
if [[ "$__ms_source_etc_profile" == yes ]] ; then
# We cannot simply load the module command. The GAEA
# /etc/profile modifies a number of module-related variables
# before loading the module command. Without those variables,
# the module command fails. Hence we actually have to source
# /etc/profile here.
source /etc/profile
unset __ms_source_etc_profile
fi
module reset
target=gaea
elif [[ "$(hostname)" =~ "Orion" ]]; then
target="orion"
Expand Down Expand Up @@ -102,7 +76,7 @@ else
echo WARNING: UNKNOWN PLATFORM 1>&2; exit 99
else
if [[ "${PW_CSP}" == "aws" || "${PW_CSP}" == "azure" || "${PW_CSP}" == "google" ]]; then
target=noaacloud
target=noaacloud
module purge
else
echo WARNING: UNSUPPORTED CSP PLATFORM 1>&2
Expand Down

0 comments on commit f1461fc

Please sign in to comment.