Skip to content

Commit

Permalink
[kvm] Add timeout for KVM tests (sonic-net#119)
Browse files Browse the repository at this point in the history
Signed-off-by: Danny Allen <daall@microsoft.com>
  • Loading branch information
daall authored Jun 25, 2020
1 parent f01445c commit daea1a7
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 6 deletions.
4 changes: 3 additions & 1 deletion jenkins/mgmt/sonic-mgmt-canary/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,9 @@ pipeline {
lock(resource: "kvmtest_${env.NODE_NAME}") {
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/test.sh'
timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion jenkins/mgmt/sonic-mgmt-pr/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,9 @@ pipeline {
lock(resource: "kvmtest_${env.NODE_NAME}") {
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/test.sh'
timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion jenkins/vs/buildimage-vs-image-201911-test/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ pipeline {
lock(resource: "kvmtest_${env.NODE_NAME}") {
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/test.sh'
timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down
5 changes: 4 additions & 1 deletion jenkins/vs/buildimage-vs-image-pr/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,10 @@ sudo cp ../target/sonic-vs.bin /nfs/jenkins/sonic-vs-${JOB_NAME##*/}.${BUILD_NUM
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/build_kvm_image.sh'
sh './scripts/vs/buildimage-vs-image/test.sh'

timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down
4 changes: 3 additions & 1 deletion jenkins/vs/buildimage-vs-image-test/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ pipeline {
lock(resource: "kvmtest_${env.NODE_NAME}") {
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/test.sh'
timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down
5 changes: 4 additions & 1 deletion jenkins/vs/buildimage-vs-image/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,10 @@ sudo cp ../target/sonic-vs-dbg.bin /nfs/jenkins/sonic-vs-dbg-${JOB_NAME##*/}.${B
withCredentials([sshUserPrivateKey(credentialsId: '2b6b6afe-4892-41d1-967c-d683e7773727', keyFileVariable: 'VM_USER_PRIVATE_KEY'), \
usernamePassword(credentialsId: 'sonicdev-cr', usernameVariable: 'REGISTRY_USERNAME', passwordVariable: 'REGISTRY_PASSWD')]) {
sh './scripts/vs/buildimage-vs-image/build_kvm_image.sh'
sh './scripts/vs/buildimage-vs-image/test.sh'

timeout(time: 2, unit: 'HOURS') {
sh './scripts/vs/buildimage-vs-image/test.sh'
}
}
}
}
Expand Down

0 comments on commit daea1a7

Please sign in to comment.