-
Notifications
You must be signed in to change notification settings - Fork 168
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create gw_setup script and extend to other machines (#1706)
* Create gw_setup script and extend to other machines Add a new script to handle setting up the lmod environment needed to run all the setup for checkout and experiment generation. C `checkout.sh` now uses this script as more recent versions of `git` are needed on some machines. Documentation has been updated to recommend this method on all machines rather than the previous instructions. Updates documentation to add the checkout with UFSDA option. Closes #1677
- Loading branch information
1 parent
4f03d8b
commit cfc3d9c
Showing
8 changed files
with
85 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
help([[ | ||
Load environment to run GFS workflow setup scripts on Jet | ||
]]) | ||
|
||
load(pathJoin("rocoto", "1.3.3")) | ||
|
||
if (mode() == "unload") then | ||
-- `execute` delays commands until last, but we need conda deactivated | ||
-- before unloading miniconda. `print` (bizarrely) still executes the | ||
-- command, but does it immediately. The semicolon is necessary | ||
-- because otherwise other commands get tacked onto the same line. | ||
print("conda deactivate;") | ||
end | ||
|
||
-- Temporary until official hpc-stack is updated | ||
prepend_path("MODULEPATH", "/mnt/lfs4/HFIP/hfv3gfs/role.epic/miniconda3/modulefiles") | ||
load(pathJoin("miniconda3", "4.12.0")) | ||
if (mode() == "load") then | ||
execute{cmd="conda activate ufswm", modeA={"load"}} | ||
end | ||
|
||
whatis("Description: GFS run setup environment") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
help([[ | ||
Load environment to run GFS workflow setup scripts on S4 | ||
]]) | ||
|
||
load(pathJoin("miniconda", "3.8-s4")) | ||
load(pathJoin("rocoto","1.3.5")) | ||
load(pathJoin("git","2.30.0")) | ||
|
||
whatis("Description: GFS run setup environment") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
help([[ | ||
Load environment to run GFS workflow ci scripts on WCOSS2 | ||
]]) | ||
|
||
load(pathJoin("git","2.29.0")) | ||
|
||
prepend_path("MODULEPATH", "/apps/ops/test/nco/modulefiles/core") | ||
load(pathJoin("rocoto","1.3.5")) | ||
|
||
whatis("Description: GFS run ci top-level sripts environment") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#! /bin/bash | ||
|
||
# | ||
# Resets the lmod environment and loads the modules necessary to run all the | ||
# scripts necessary to prepare the workflow for use (checkout, experiment | ||
# setup, etc.). | ||
# | ||
# This script should be SOURCED to properly setup the environment. | ||
# | ||
|
||
HOMEgfs="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." >/dev/null 2>&1 && pwd )" | ||
source "${HOMEgfs}/ush/detect_machine.sh" | ||
source "${HOMEgfs}/ush/module-setup.sh" | ||
module use "${HOMEgfs}/modulefiles" | ||
module load "module_gwsetup.${MACHINE_ID}" |