From 4b819ee1920f16e676a2c393328dffd72335fa8d Mon Sep 17 00:00:00 2001 From: zhuwenxing Date: Mon, 25 Jul 2022 17:56:29 +0800 Subject: [PATCH] [skip e2e]Update jenkinsfile for new image repo (#18402) Signed-off-by: zhuwenxing --- build/ci/jenkins/ChaosTest.groovy | 11 ++++++----- build/ci/jenkins/ChaosTestKafkaMQ.groovy | 11 ++++++----- build/ci/jenkins/DeployTest.groovy | 2 +- build/ci/jenkins/DeployTestKafkaMQ.groovy | 2 +- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/build/ci/jenkins/ChaosTest.groovy b/build/ci/jenkins/ChaosTest.groovy index 2bf59bd545..1a78b29d7c 100644 --- a/build/ci/jenkins/ChaosTest.groovy +++ b/build/ci/jenkins/ChaosTest.groovy @@ -34,7 +34,7 @@ pipeline { string( description: 'Image Repository', name: 'image_repository', - defaultValue: 'registry.milvus.io/milvus/milvus' + defaultValue: 'harbor.milvus.io/dockerhub/milvusdb/milvus' ) string( description: 'Image Tag', @@ -140,14 +140,15 @@ pipeline { sh "echo ${params.chaos_type}" sh "helm repo add milvus https://milvus-io.github.io/milvus-helm" sh "helm repo update" - if ("${params.pod_name}" == "standalone"){ + def pod_name = "${params.pod_name}" + if (pod_name.contains("standalone")){ sh""" IMAGE_TAG="${image_tag_modified}" \ REPOSITORY="${params.image_repository}" \ RELEASE_NAME="${env.RELEASE_NAME}" \ bash install_milvus_standalone.sh """ - }else{ + }else{ sh""" IMAGE_TAG="${image_tag_modified}" \ REPOSITORY="${params.image_repository}" \ @@ -215,11 +216,11 @@ pipeline { if ("${params.chaos_task}" == "chaos-test"){ def host = sh(returnStdout: true, script: "kubectl get svc/${env.RELEASE_NAME}-milvus -o jsonpath=\"{.spec.clusterIP}\"").trim() - sh "pytest -s -v test_chaos.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " + sh "timeout 14m pytest -s -v test_chaos.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " } if ("${params.chaos_task}" == "data-consist-test"){ def host = sh(returnStdout: true, script: "kubectl get svc/${env.RELEASE_NAME}-milvus -o jsonpath=\"{.spec.clusterIP}\"").trim() - sh "pytest -s -v test_chaos_data_consist.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " + sh "timeout 14m pytest -s -v test_chaos_data_consist.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " } echo "chaos test done" sh "kubectl wait --for=condition=Ready pod -l app.kubernetes.io/instance=${env.RELEASE_NAME} -n ${env.NAMESPACE} --timeout=360s" diff --git a/build/ci/jenkins/ChaosTestKafkaMQ.groovy b/build/ci/jenkins/ChaosTestKafkaMQ.groovy index ecd47bcadd..0d3f774fd9 100644 --- a/build/ci/jenkins/ChaosTestKafkaMQ.groovy +++ b/build/ci/jenkins/ChaosTestKafkaMQ.groovy @@ -34,7 +34,7 @@ pipeline { string( description: 'Image Repository', name: 'image_repository', - defaultValue: 'registry.milvus.io/milvus/milvus' + defaultValue: 'harbor.milvus.io/dockerhub/milvusdb/milvus' ) string( description: 'Image Tag', @@ -142,14 +142,15 @@ pipeline { sh "echo ${params.chaos_type}" sh "helm repo add milvus https://milvus-io.github.io/milvus-helm" sh "helm repo update" - if ("${params.pod_name}" == "standalone"){ + def pod_name = "${params.pod_name}" + if (pod_name.contains("standalone")){ sh""" IMAGE_TAG="${image_tag_modified}" \ REPOSITORY="${params.image_repository}" \ RELEASE_NAME="${env.RELEASE_NAME}" \ bash install_milvus_standalone.sh """ - }else{ + }else{ sh""" IMAGE_TAG="${image_tag_modified}" \ REPOSITORY="${params.image_repository}" \ @@ -217,11 +218,11 @@ pipeline { if ("${params.chaos_task}" == "chaos-test"){ def host = sh(returnStdout: true, script: "kubectl get svc/${env.RELEASE_NAME}-milvus -o jsonpath=\"{.spec.clusterIP}\"").trim() - sh "pytest -s -v test_chaos.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " + sh "timeout 14m pytest -s -v test_chaos.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " } if ("${params.chaos_task}" == "data-consist-test"){ def host = sh(returnStdout: true, script: "kubectl get svc/${env.RELEASE_NAME}-milvus -o jsonpath=\"{.spec.clusterIP}\"").trim() - sh "pytest -s -v test_chaos_data_consist.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " + sh "timeout 14m pytest -s -v test_chaos_data_consist.py --host $host --log-cli-level=INFO --capture=no || echo 'chaos test fail' " } echo "chaos test done" sh "kubectl wait --for=condition=Ready pod -l app.kubernetes.io/instance=${env.RELEASE_NAME} -n ${env.NAMESPACE} --timeout=360s" diff --git a/build/ci/jenkins/DeployTest.groovy b/build/ci/jenkins/DeployTest.groovy index bdd324b05c..c449a58fa0 100644 --- a/build/ci/jenkins/DeployTest.groovy +++ b/build/ci/jenkins/DeployTest.groovy @@ -41,7 +41,7 @@ pipeline { string( description: 'New Image Repository', name: 'new_image_repository', - defaultValue: 'registry.milvus.io/milvus/milvus' + defaultValue: 'harbor.milvus.io/dockerhub/milvusdb/milvus' ) string( description: 'New Version Image Tag', diff --git a/build/ci/jenkins/DeployTestKafkaMQ.groovy b/build/ci/jenkins/DeployTestKafkaMQ.groovy index 1b957cbc37..57c4d6d1a2 100644 --- a/build/ci/jenkins/DeployTestKafkaMQ.groovy +++ b/build/ci/jenkins/DeployTestKafkaMQ.groovy @@ -41,7 +41,7 @@ pipeline { string( description: 'New Image Repository', name: 'new_image_repository', - defaultValue: 'registry.milvus.io/milvus/milvus' + defaultValue: 'harbor.milvus.io/dockerhub/milvusdb/milvus' ) string( description: 'New Version Image Tag',