Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix jenkins rostam config #395

Merged
merged 14 commits into from
Jan 12, 2022
38 changes: 8 additions & 30 deletions .jenkins/lsu/Jenkinsfile-Node-Level
Original file line number Diff line number Diff line change
Expand Up @@ -2,49 +2,27 @@

def buildbadge = addEmbeddableBadgeConfiguration(id: "nodelevel", subject: "CPU / GPU Kernel Tests", status: "skipped")

// Skip builds that are likely to be tested already (by push) and unlikely to be critical (not on master)
if (currentBuild.getBuildCauses().toString().contains('BranchIndexingCause')) {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by branch indexing..."
if (env.BRANCH_NAME != "master") { // Always run on master
if (env.BUILD_NUMBER != "1") { // Always run first build on a new branch pipeline to load the options (and thus github hook triggers) for the pipeline
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} skipped due being triggered by Branch Indexing instead of SCM change!"
currentBuild.result = 'ABORTED'
buildbadge.setStatus('skipped')
return // Early exit to avoid redundant builds
}
}
} else {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by SCM change..."
print "Proceeding!"
}


pipeline {
agent any

options {
buildDiscarder(
logRotator(
daysToKeepStr: "21",
numToKeepStr: "50",
artifactDaysToKeepStr: "21",
artifactNumToKeepStr: "50"
daysToKeepStr: "28",
numToKeepStr: "100",
artifactDaysToKeepStr: "28",
artifactNumToKeepStr: "100"
)
)
disableConcurrentBuilds()
}
triggers {
githubPush() // Trigger by push to respective github branch
pollSCM 'H/5 * * * *' // Fallback polling solution as some pushes are somehow lost
}
environment {
GITHUB_TOKEN = credentials('GITHUB_TOKEN_OCTOTIGER')
MAINTAINER_MAIL = credentials('OCTOTIGER_MAINTAINER_EMAIL')
}
stages {
stage('checkout') {
steps {
scmSkip(deleteBuild: false, skipPattern:'.*\\[ci skip\\].*')
script {
buildbadge.setStatus('running')
}
Expand All @@ -54,7 +32,6 @@ pipeline {
cd octotiger
git submodule update --init --recursive
cd ..
echo "Build started on pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger Node-Level Tests: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} just started..." "${MAINTAINER_MAIL}"
'''
}
}
Expand Down Expand Up @@ -115,12 +92,16 @@ pipeline {
git checkout main
git pull
rm -rf build/octotiger
rm -rf build/kokkos
rm -rf src/octotiger
else
git clone https://github.com/diehlpk/PowerTiger.git "octo-buildscripts-${compiler_config}-${cuda_config}-${kokkos_config}"
cd "octo-buildscripts-${compiler_config}-${cuda_config}-${kokkos_config}"
git checkout main # change to different branch if needed for target machine
mkdir src
rm -rf build/octotiger
rm -rf build/kokkos
rm -rf src/octotiger
fi

cd ..
Expand Down Expand Up @@ -199,9 +180,6 @@ pipeline {
script {
buildbadge.setStatus('success')
}
sh '''
echo "Build succeded! Pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger Node-Level Tests: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} succeded" "${MAINTAINER_MAIL}"
'''
}
failure {
script {
Expand Down
18 changes: 13 additions & 5 deletions .jenkins/lsu/node-level-tests-entry.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,19 @@
set -eux

#default: Assume gcc
compiler_module="gcc/9.3.0"
compiler_module="gcc/9.4.0"
simd_config="with-simd"

# if clang: change modules and no blast test (no quadmath..)
if [ "${compiler_config}" = "with-CC-clang" ]; then
compiler_module="clang/11.0.1"
compiler_module="llvm/11.1.0"
sed -i 's/OCTOTIGER_WITH_BLAST_TEST=ON/OCTOTIGER_WITH_BLAST_TEST=OFF/' build-octotiger.sh
fi
# Test gcc 9.4.0 and nvcc without kokkos simd types for now
if [ "${compiler_config}" = "with-CC" ] && [ "${kokkos_config}" = "with-kokkos" ] && [ "${kokkos_config}" = "with-kokkos" ]; then
simd_config="without-simd"
fi


# Load everything
echo "Loading modules: "
Expand All @@ -18,18 +24,20 @@ module load "${compiler_module}" cuda/11.4 hwloc
# Tests with griddim = 8
if [ "${kokkos_config}" = "with-kokkos" ]; then
echo "Running tests with griddim=8 on diablo"
srun -p QxV100 -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} with-simd with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling boost jemalloc hdf5 silo vc hpx kokkos cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "
srun -p cuda -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} ${simd_config} with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling without-otf2 boost jemalloc hdf5 silo vc hpx kokkos cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "

# Tests with griddim = 16 - only test in full kokkos + cuda build
if [ "${cuda_config}" = "with-cuda" ]; then
sed -i 's/GRIDDIM=8/GRIDDIM=16/' build-octotiger.sh
echo "Running tests with griddim=16 on diablo"
srun -p QxV100 -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} with-simd with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling boost jemalloc hdf5 silo vc hpx kokkos cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "
rm -rf build/kokkos build/octotiger # in case we end up on a different cuda node we need to rebuild with its architecture
srun -p cuda -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} ${simd_config} with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling without-otf2 boost jemalloc hdf5 silo vc hpx kokkos cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "
sed -i 's/GRIDDIM=16/GRIDDIM=8/' build-octotiger.sh
fi
else
# TODO Run this on a different server as intended to cut the test time?
echo "Running tests with griddim=8 on diablo"
srun -p QxV100 -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} with-simd with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling boost jemalloc hdf5 silo vc hpx cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "
srun -p cuda -N 1 -n 1 -t 08:00:00 bash -c "module load ${compiler_module} cuda/11.4 hwloc && ./build-all.sh Release ${compiler_config} ${cuda_config} without-mpi without-papi without-apex ${kokkos_config} ${simd_config} with-hpx-backend-multipole without-hpx-backend-monopole with-hpx-cuda-polling without-otf2 boost jemalloc hdf5 silo vc hpx cppuddle octotiger && cd build/octotiger/build && ctest --output-on-failure "
fi

# Reset buildscripts (in case of failure, the next job will reset it in the checkout step)
Expand Down
29 changes: 4 additions & 25 deletions .jenkins/stuttgart/Jenkinsfile-DEV-NODE
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,20 @@

def buildbadge = addEmbeddableBadgeConfiguration(id: "devbuild", subject: "Dev-Environment Tests", status: "skipped")

if (currentBuild.getBuildCauses().toString().contains('BranchIndexingCause')) {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by branch indexing..."
if (env.BRANCH_NAME != "master") {
if (env.BUILD_NUMBER != "1") { // Always execute first build to load this configuration and thus the triggers
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} skipped due being triggered by Branch Indexing instead of SCM change!"
buildbadge.setStatus('skipped')
currentBuild.result = 'ABORTED'
return // early exit to avoid redundant builds
}
}
} else {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by SCM change..."
print "Proceeding!"
}


pipeline {
agent { label 'pcsgs05' }

options {
buildDiscarder(
logRotator(
daysToKeepStr: "21",
numToKeepStr: "50",
artifactDaysToKeepStr: "21",
artifactNumToKeepStr: "50"
daysToKeepStr: "28",
numToKeepStr: "100",
artifactDaysToKeepStr: "28",
artifactNumToKeepStr: "100"
)
)
disableConcurrentBuilds()
}
triggers {
githubPush() // Trigger by push to respective github branch
pollSCM 'H/30 * * * *' // Fallback polling solution as some pushes are somehow lost
}
environment {
GITHUB_TOKEN = credentials('GITHUB_TOKEN_OCTOTIGER')
NEXTCLOUD_OCTOTIGER_DEPENDENCIES_TOKEN = credentials('NEXTCLOUD_OCTOTIGER_DEPENDENCIES_TOKEN')
Expand All @@ -44,7 +24,6 @@ pipeline {
stages {
stage('init') {
steps {
scmSkip(deleteBuild: false, skipPattern:'.*\\[ci skip\\].*')
script {
buildbadge.setStatus('running')
}
Expand Down
32 changes: 4 additions & 28 deletions .jenkins/stuttgart/Jenkinsfile-KNL
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,20 @@

def buildbadge = addEmbeddableBadgeConfiguration(id: "knlbuild", subject: "KNL Kokkos SIMD Tests", status: "skipped")

if (currentBuild.getBuildCauses().toString().contains('BranchIndexingCause')) {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by branch indexing..."
if (env.BRANCH_NAME != "master") {
if (env.BUILD_NUMBER != "1") { // Always execute first build to load this configuration and thus the triggers
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} skipped due being triggered by Branch Indexing instead of SCM change!"
buildbadge.setStatus('skipped')
currentBuild.result = 'ABORTED'
return // early exit to avoid redundant builds
}
}
} else {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by SCM change..."
print "Proceeding!"
}



pipeline {
agent { label 'argon-fs' }

options {
buildDiscarder(
logRotator(
daysToKeepStr: "21",
numToKeepStr: "50",
artifactDaysToKeepStr: "21",
artifactNumToKeepStr: "50"
daysToKeepStr: "28",
numToKeepStr: "100",
artifactDaysToKeepStr: "28",
artifactNumToKeepStr: "100"
)
)
disableConcurrentBuilds()
}
triggers {
githubPush() // Trigger by push to respective github branch
pollSCM 'H/30 * * * *' // Fallback polling solution as some pushes are somehow lost
}
environment {
GITHUB_TOKEN = credentials('GITHUB_TOKEN_OCTOTIGER')
NEXTCLOUD_OCTOTIGER_DEPENDENCIES_TOKEN = credentials('NEXTCLOUD_OCTOTIGER_DEPENDENCIES_TOKEN')
Expand All @@ -45,7 +24,6 @@ pipeline {
stages {
stage('init') {
steps {
scmSkip(deleteBuild: false, skipPattern:'.*\\[ci skip\\].*')
script {
buildbadge.setStatus('running')
}
Expand All @@ -63,7 +41,6 @@ pipeline {
\\"description\\": \\"Jenkins CI Job: jenkins-KNL-SIMD\\",
\\"target_url\\": \\"https://simsgs.informatik.uni-stuttgart.de/jenkins/job/Octo-Tiger%20KNL/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/console\\"
}"
echo "Build started on pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger KNL: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} just started..." "${MAINTAINER_MAIL}"
'''
}
}
Expand Down Expand Up @@ -183,7 +160,6 @@ pipeline {
\\"description\\": \\"Jenkins CI Job: jenkins-KNL-SIMD\\",
\\"target_url\\": \\"https://simsgs.informatik.uni-stuttgart.de/jenkins/job/Octo-Tiger%20KNL/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/console\\"
}"
echo "Build succeded on pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger KNL: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} succeded" "${MAINTAINER_MAIL}"
'''
}
failure {
Expand Down
30 changes: 4 additions & 26 deletions .jenkins/stuttgart/Jenkinsfile-POWER9
Original file line number Diff line number Diff line change
Expand Up @@ -2,39 +2,20 @@

def buildbadge = addEmbeddableBadgeConfiguration(id: "powerbuild", subject: "Power9 CUDA/Kokkos Tests", status: "skipped")

if (currentBuild.getBuildCauses().toString().contains('BranchIndexingCause')) {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by branch indexing..."
if (env.BRANCH_NAME != "master") {
if (env.BUILD_NUMBER != "1") { // Always execute first build to load this configuration and thus the triggers
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} skipped due being triggered by Branch Indexing instead of SCM change!"
buildbadge.setStatus('skipped')
currentBuild.result = 'ABORTED'
return // early exit to avoid redundant builds
}
}
} else {
print "INFO: Build on ${env.BRANCH_NAME}/${env.BUILD_NUMBER} triggered by SCM change..."
print "Proceeding!"
}

pipeline {
agent { label 'argon-fs' }

options {
buildDiscarder(
logRotator(
daysToKeepStr: "21",
numToKeepStr: "50",
artifactDaysToKeepStr: "21",
artifactNumToKeepStr: "50"
daysToKeepStr: "28",
numToKeepStr: "100",
artifactDaysToKeepStr: "28",
artifactNumToKeepStr: "100"
)
)
disableConcurrentBuilds()
}
triggers {
githubPush() // Trigger by push to respective github branch
pollSCM 'H/30 * * * *' // Fallback polling solution as some pushes are somehow lost
}

environment {
GITHUB_TOKEN = credentials('GITHUB_TOKEN_OCTOTIGER')
Expand All @@ -44,7 +25,6 @@ pipeline {
stages {
stage('init') {
steps {
scmSkip(deleteBuild: false, skipPattern:'.*\\[ci skip\\].*')
script {
buildbadge.setStatus('running')
}
Expand All @@ -62,7 +42,6 @@ pipeline {
\\"description\\": \\"Jenkins CI Job: jenkins-POWER9\\",
\\"target_url\\": \\"https://simsgs.informatik.uni-stuttgart.de/jenkins/job/Octo-Tiger%20POWER9/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/console\\"
}"
echo "Build started on pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger POWER9: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} just started..." "${MAINTAINER_MAIL}"
'''
}
}
Expand Down Expand Up @@ -151,7 +130,6 @@ pipeline {
\\"description\\": \\"Jenkins CI Job: jenkins-POWER9\\",
\\"target_url\\": \\"https://simsgs.informatik.uni-stuttgart.de/jenkins/job/Octo-Tiger%20POWER9/job/${JOB_BASE_NAME}/${BUILD_NUMBER}/console\\"
}"
echo "Build succeded on pipeline ${JOB_BASE_NAME} with build ID ${BUILD_NUMBER} using GIT commit ${GIT_COMMIT}" | mail -s "Jenkins Octo-Tiger POWER9: Build ${JOB_BASE_NAME}/${BUILD_NUMBER} succeded" "${MAINTAINER_MAIL}"
'''
}
failure {
Expand Down