Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
f071994
change noaacloud NodeName
weihuang-jedi Feb 25, 2025
11accd8
Merge branch 'develop' of github.com:NOAA-EPIC/global-workflow-cloud …
weihuang-jedi Feb 26, 2025
a4771df
add download fix subset data, also serve as a test PR to trigger CI t…
weihuang-jedi Feb 26, 2025
4f1e679
fix pynorm error
weihuang-jedi Feb 26, 2025
2241227
fix pynorm error 2
weihuang-jedi Feb 26, 2025
9679617
fix pynorm error3
weihuang-jedi Feb 26, 2025
fe88751
fix pynorm error 4
weihuang-jedi Feb 26, 2025
0284fb7
fix pynorm error 5
weihuang-jedi Feb 26, 2025
27ca2f1
fix pynorm error 6
weihuang-jedi Feb 26, 2025
f39bfd9
fix pynorm error 7
weihuang-jedi Feb 27, 2025
8f7fc23
fix pynorm error 8
weihuang-jedi Feb 27, 2025
c248e12
fix pynorm error 9
weihuang-jedi Feb 27, 2025
85120f3
fix pynorm error 10
weihuang-jedi Feb 27, 2025
2a7f1c9
fix a syntax error
weihuang-jedi Feb 27, 2025
9f8ee2d
use just /lutre/jenkins for CI testing work directory
weihuang-jedi Feb 27, 2025
fbeb220
Merge branch 'develop' of github.com:NOAA-EPIC/global-workflow-cloud …
weihuang-jedi Feb 28, 2025
df4179c
using argparse and logging instead of getopt and print
weihuang-jedi Mar 3, 2025
6a168ae
using argparse and logging instead of getopt and print
weihuang-jedi Mar 3, 2025
a23662f
Updating with proper nomenclature.
kbooker79 Mar 3, 2025
3c223cf
Merge pull request #5 from NOAA-EPIC/download-subset-fix-data
kbooker79 Mar 3, 2025
6b60421
consist with Terry's code
weihuang-jedi Mar 3, 2025
35f35f2
add a ls command to make sure code in cloned
weihuang-jedi Mar 3, 2025
9e53aa4
try clone the code directly
weihuang-jedi Mar 3, 2025
98c50d9
use https to clone
weihuang-jedi Mar 3, 2025
b4c507f
Merge branch 'NOAA-EMC:develop' into develop
weihuang-jedi Mar 4, 2025
3089f00
add more debug ls
weihuang-jedi Mar 4, 2025
57b2a51
fix a typo
weihuang-jedi Mar 4, 2025
8fefe2a
remove 2 comments
weihuang-jedi Mar 4, 2025
8f6db95
reset HOMEgfs
weihuang-jedi Mar 4, 2025
1f05a51
compile for gfs only for now
weihuang-jedi Mar 4, 2025
4640b6a
comment gh pr eidt for now
weihuang-jedi Mar 5, 2025
c906547
skip CI on AWS
weihuang-jedi Mar 5, 2025
eac272e
trying to fix runtime bug
weihuang-jedi Mar 5, 2025
35a6cd0
still trying to figure out HOEgfs issue
weihuang-jedi Mar 5, 2025
b55f4a1
add compile gefs
weihuang-jedi Mar 5, 2025
e1724cb
add compile gefs
weihuang-jedi Mar 5, 2025
4264c15
add compile gefs
weihuang-jedi Mar 5, 2025
20c1211
switch back to 'checkout scm instead of git clone'
weihuang-jedi Mar 11, 2025
f8a6a6d
using checkout scm
weihuang-jedi Mar 12, 2025
c952a73
using checkout scm
weihuang-jedi Mar 12, 2025
b79f94a
Updating with new Jenkinsfile.
kbooker79 Mar 12, 2025
80bac6b
Updating.
kbooker79 Mar 12, 2025
d404362
Updating.
kbooker79 Mar 12, 2025
ceb8172
Updating.
kbooker79 Mar 12, 2025
12b09df
remove memory from resource if on AWS
weihuang-jedi Mar 13, 2025
98570b7
remove memory requirement for AWS
weihuang-jedi Mar 13, 2025
8c9a93a
check current dir
weihuang-jedi Mar 13, 2025
b13b189
check current dir
weihuang-jedi Mar 13, 2025
550b4aa
check current dir
weihuang-jedi Mar 14, 2025
34146f1
check current dir
weihuang-jedi Mar 14, 2025
29db99b
define WORKSPACE
weihuang-jedi Mar 14, 2025
9a08330
define WORKSPACE
weihuang-jedi Mar 14, 2025
167976e
define WORKSPACE
weihuang-jedi Mar 14, 2025
b49f21d
trying reset workspace
weihuang-jedi Mar 14, 2025
79b65bb
trying reset workspace
weihuang-jedi Mar 14, 2025
60100eb
Updating.
kbooker79 Mar 14, 2025
7dcecb9
Fixing naming convention.
kbooker79 Mar 14, 2025
fb0238e
Fixing syntax issue.
kbooker79 Mar 14, 2025
a33fc96
Fixing paths, again.
kbooker79 Mar 14, 2025
4eb5dfe
Updating.
kbooker79 Mar 14, 2025
ebfd864
Updating.
kbooker79 Mar 14, 2025
fb5ff0b
correct runtest dire
weihuang-jedi Mar 15, 2025
2039132
Merge branch 'NOAA-EMC:develop' into develop
weihuang-jedi Mar 16, 2025
6a7b1b8
add C48_S2SW test
weihuang-jedi Mar 16, 2025
7b59ba6
Merge remote-tracking branch 'origin/develop' into ci-testing-on-aws-kb
weihuang-jedi Mar 16, 2025
4d70d48
need to compile gefs
weihuang-jedi Mar 17, 2025
9148fc8
prepare to run CI testing from EMC repo
weihuang-jedi Mar 17, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 23 additions & 11 deletions ci/Jenkinsfile4AWS
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,12 @@ def CUSTOM_WORKSPACE = 'none'
def HOMEgfs = 'none'
def CI_CASES = ''
def GH = 'none'
//Trivial change
// Location of the custom workspaces for each machine in the CI system. They are persistent for each iteration of the PR.
def NodeName = [hera: 'Hera-EMC', orion: 'Orion-EMC', hercules: 'Hercules-EMC', gaea: 'Gaea', noaacloud: 'awsepicglobalworkflow']
def custom_workspace = [hera: '/scratch1/NCEPDEV/global/CI', orion: '/work2/noaa/stmp/CI/ORION', hercules: '/work2/noaa/global/CI/HERCULES', gaea: '/gpfs/f5/epic/proj-shared/global/CI', noaacloud: '/lustre/jenkins']
def repo_url = 'git@github.com:NOAA-EMC/global-workflow.git'
def NodeName = [hera: 'Hera-EMC', orion: 'Orion-EMC', hercules: 'Hercules-EMC', gaea: 'Gaea', awsepicglobalworkflow: 'Awsepicglobalworkflow']
def custom_workspace = [hera: '/scratch1/NCEPDEV/global/CI', orion: '/work2/noaa/stmp/CI/ORION', hercules: '/work2/noaa/global/CI/HERCULES', gaea: '/gpfs/f5/epic/proj-shared/global/CI', awsepicglobalworkflow: '/lustre/jenkins']
def repo_url = 'https://github.com/NOAA-EMC/global-workflow.git'
def aws_gw_name = 'global-workflow'
def STATUS = 'Passed'

pipeline {
Expand Down Expand Up @@ -44,7 +46,9 @@ pipeline {
for (label in pullRequest.labels) {
if (label.matches("CI-(.*?)-Ready")) {
def machine_name = label.split('-')[1].toString().toLowerCase()
print machine_name
jenkins.model.Jenkins.get().computers.each { c ->
print c.node.selfLabel.name
if (c.node.selfLabel.name == NodeName[machine_name]) {
run_nodes.add(c.node.selfLabel.name)
}
Expand All @@ -56,7 +60,7 @@ pipeline {
run_nodes.init().each { node ->
def machine_name = node.split('-')[0].toLowerCase()
echo "Spawning job on node: ${node} with machine name: ${machine_name}"
build job: "/global-workflow/EMC-Global-Pipeline/PR-${env.CHANGE_ID}", parameters: [
build job: "/${aws_gw_name}/EPIC-AWS-CI-Pipeline/PR-${env.CHANGE_ID}", parameters: [
string(name: 'machine', value: machine_name),
string(name: 'Node', value: node) ],
wait: false
Expand All @@ -79,11 +83,11 @@ pipeline {
Machine = machine[0].toUpperCase() + machine.substring(1)
echo "Getting Common Workspace for ${Machine}"
ws("${custom_workspace[machine]}/${env.CHANGE_ID}") {
properties([parameters([[$class: 'NodeParameterDefinition', allowedSlaves: ['built-in', 'Hercules-EMC', 'Hera-EMC', 'Orion-EMC', 'Gaea', 'awsepicglobalworkflow'], defaultSlaves: ['built-in'], name: '', nodeEligibility: [$class: 'AllNodeEligibility'], triggerIfResult: 'allCases']])])
properties([parameters([[$class: 'NodeParameterDefinition', allowedSlaves: ['built-in', 'Hercules-EMC', 'Hera-EMC', 'Orion-EMC', 'Gaea', 'Awsepicglobalworkflow'], defaultSlaves: ['built-in'], name: '', nodeEligibility: [$class: 'AllNodeEligibility'], triggerIfResult: 'allCases']])])
GH = sh(script: "which gh || echo '~/bin/gh'", returnStdout: true).trim()
CUSTOM_WORKSPACE = "${WORKSPACE}"
HOMEgfs = "${CUSTOM_WORKSPACE}/global-workflow"
sh(script: "rm -Rf ${CUSTOM_WORKSPACE}/global-workflow; mkdir -p ${CUSTOM_WORKSPACE}/global-workflow")
CUSTOM_WORKSPACE = "${custom_workspace[machine]}/${env.CHANGE_ID}/${aws_gw_name}"
HOMEgfs = "${CUSTOM_WORKSPACE}/${aws_gw_name}"
sh(script: "rm -Rf ${CUSTOM_WORKSPACE}; mkdir -p ${CUSTOM_WORKSPACE}/${aws_gw_name}")
sh(script: "rm -Rf ${CUSTOM_WORKSPACE}/RUNTESTS; mkdir -p ${CUSTOM_WORKSPACE}/RUNTESTS")
sh(script: """${GH} pr edit ${env.CHANGE_ID} --repo ${repo_url} --add-label "CI-${Machine}-Building" --remove-label "CI-${Machine}-Ready" """)
}
Expand All @@ -95,17 +99,23 @@ pipeline {
stage('3. Build System') {
agent { label NodeName[machine].toLowerCase() }
steps {
dir("${HOMEgfs}") {
checkout scm
}
catchError(buildResult: 'UNSTABLE', stageResult: 'FAILURE') {
script {
ws(HOMEgfs) {
echo "Checking out the code on ${Machine} using scm in ${HOMEgfs}"
try {
checkout scm
//sh(script: "git clone --recursive ${repo_url}")
sh(script: "ls ${HOMEgfs}")
} catch (Exception e) {
echo "Failed to checkout the code on ${Machine} using scm in ${HOMEgfs}, try again ..."
sleep time: 45, unit: 'SECONDS'
try {
checkout scm
// checkout scm
//sh(script: "git clone --recursive ${repo_url}")
sh(script: "ls ${HOMEgfs}/sorc")
} catch (Exception ee) {
echo "Failed to checkout the code on ${Machine} using scm in ${HOMEgfs}: ${ee.getMessage()}"
if (env.CHANGE_ID) {
Expand All @@ -120,7 +130,9 @@ pipeline {
def error_logs_message = ""
dir("${HOMEgfs}/sorc") {
try {
sh(script: './build_compute.sh all') // build the global-workflow executables
sh(script: 'ls ./build_compute.sh') // list files here to make sure all files exist.
sh(script: './build_compute.sh gfs') // build the global-workflow executables
sh(script: './build_compute.sh gefs') // build the global-workflow executables
} catch (Exception error_build) {
echo "Failed to build global-workflow: ${error_build.getMessage()}"
if ( fileExists("logs/error.logs") ) {
Expand Down
1 change: 1 addition & 0 deletions ci/cases/pr/C48_S2SW.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ arguments:
idate: 2021032312
edate: 2021032312
yaml: {{ HOMEgfs }}/ci/cases/yamls/gfs_defaults_ci.yaml

1 change: 1 addition & 0 deletions ci/cases/pr/C48_S2SW_extended.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,5 @@ skip_ci_on_hosts:
- gaeac6
- orion
- hercules
- awsepicglobalworkflow
- wcoss2 # TODO run on WCOSS2 once the gfs_waveawipsbulls job is fixed
1 change: 1 addition & 0 deletions ci/cases/pr/C48mx500_3DVarAOWCDA.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@ skip_ci_on_hosts:
- gaeac6
- gaeac5
- orion
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C48mx500_hybAOWCDA.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ skip_ci_on_hosts:
- gaeac5
- gaeac6
- orion
- awsepicglobalworkflow
3 changes: 3 additions & 0 deletions ci/cases/pr/C96C48_hybatmDA.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@ arguments:
interval: 24
start: cold
yaml: {{ HOMEgfs }}/ci/cases/yamls/gfs_defaults_ci.yaml

skip_ci_on_hosts:
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C96C48_hybatmaerosnowDA.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ skip_ci_on_hosts:
- gaeac5
- gaeac6
- hercules
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C96C48_ufs_hybatmDA.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ skip_ci_on_hosts:
- gaeac6
- orion
- hercules
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C96_atm3DVar.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ arguments:

skip_ci_on_hosts:
- wcoss2
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C96_atm3DVar_extended.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ skip_ci_on_hosts:
- gaeac6
- orion
- hercules
- awsepicglobalworkflow
1 change: 1 addition & 0 deletions ci/cases/pr/C96mx100_S2S.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,4 @@ arguments:
skip_ci_on_hosts:
- gaeac6
- gaeac5
- awsepicglobalworkflow
13 changes: 11 additions & 2 deletions ci/scripts/utils/ci_utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,20 @@ function create_experiment () {
case=$(basename "${yaml_config}" .yaml) || true
export pslot=${case}_${pr_sha}

source "${HOMEgfs}/ci/platforms/config.${MACHINE_ID}"
if [[ ${MACHINE_ID} == "noaacloud" ]]; then
source "${HOMEgfs}/ci/platforms/config.${PW_CSP}"
else
source "${HOMEgfs}/ci/platforms/config.${MACHINE_ID}"
fi

source "${HOMEgfs}/workflow/gw_setup.sh"

# Remove RUNDIRS dir incase this is a retry (STMP now in host file)
STMP=$("${HOMEgfs}/ci/scripts/utils/parse_yaml.py" -y "${HOMEgfs}/workflow/hosts/${MACHINE_ID}.yaml" -k STMP -s)
if [[ ${MACHINE_ID} == "noaacloud" ]]; then
STMP=$("${HOMEgfs}/ci/scripts/utils/parse_yaml.py" -y "${HOMEgfs}/workflow/hosts/${PW_CSP}pw.yaml" -k STMP -s)
else
STMP=$("${HOMEgfs}/ci/scripts/utils/parse_yaml.py" -y "${HOMEgfs}/workflow/hosts/${MACHINE_ID}.yaml" -k STMP -s)
fi
echo "Removing ${STMP}/RUNDIRS/${pslot} directory incase this is a retry"
rm -Rf "${STMP}/RUNDIRS/${pslot}"

Expand Down
9 changes: 8 additions & 1 deletion ci/scripts/utils/launch_java_agent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ source "${HOMEGFS_}/ush/detect_machine.sh"
case ${MACHINE_ID} in
hera | orion | hercules | wcoss2 | gaeac5 | gaeac6 )
echo "Launch Jenkins Java Controler on ${MACHINE_ID}";;
noaacloud )
echo "Launch Jenkins Java Controler on ${PW_CSP}";;
*)
echo "Unsupported platform. Exiting with error."
exit 1;;
Expand All @@ -87,7 +89,12 @@ rm -f "${LOG}"
HOMEgfs="${HOMEGFS_}" source "${HOMEGFS_}/ush/module-setup.sh"
module use "${HOMEGFS_}/modulefiles"
module load "module_gwsetup.${MACHINE_ID}"
source "${HOMEGFS_}/ci/platforms/config.${MACHINE_ID}"

if [[ ${MACHINE_ID} == "noaacloud" ]]; then
source "${HOMEgfs_}/ci/platforms/config.${PW_CSP}"
else
source "${HOMEgfs_}/ci/platforms/config.${MACHINE_ID}"
fi

JAVA_HOME="${JENKINS_AGENT_LAUNCH_DIR}/JAVA/jdk-17.0.10"
if [[ ! -d "${JAVA_HOME}" ]]; then
Expand Down
14 changes: 7 additions & 7 deletions parm/config/gfs/config.resources.AWSPW
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,7 @@

export is_exclusive="True"
unset memory

# shellcheck disable=SC2312
for mem_var in $(env | grep '^memory_' | cut -d= -f1); do
unset "${mem_var}"
done

step=$1
unset "memory_${RUN}"

case ${step} in
"fcst" | "efcs")
Expand All @@ -24,6 +18,12 @@ case ${step} in
;;


"atmos_products" | "oceanice_products" | "wavepostsbs" )
export PARTITION_BATCH="process"
max_tasks_per_node=24
;;


*)
export PARTITION_BATCH="process"
max_tasks_per_node=24
Expand Down
Loading