Parcourir la source

Поправил вызов функций k8sHelmOps.upgrade и k8sHelmOps.rollback

Tomishinets Vladimir il y a 3 ans
Parent
commit
3c5f50f2a8
1 fichiers modifiés avec 2 ajouts et 4 suppressions
  1. 2 4
      devK8s.Jenkinsfile

+ 2 - 4
devK8s.Jenkinsfile

@@ -74,16 +74,14 @@ pipeline {
     stage("Update APP") {
       steps {
         script {
-          RELEASENAME = DOCKER_IMAGE.split("/")[0]
-          NAMESPACE = DOCKER_IMAGE.split("/")[0]
           try {
             echo "Update APP to ${IMAGE_TO_PUSH}"
-            k8sHelmOps.upgrade(CONTEXT, NAMESPACE, RELEASENAME, CHART_PATH, VALUES_FILE, HELM_REPO)
+            k8sHelmOps.upgrade(CONTEXT, DOCKER_IMAGE.split("/")[0], DOCKER_IMAGE.split("/")[0], CHART_PATH, VALUES_FILE, HELM_REPO)
             echo "Update success!!!"
           }
           catch(err) {
             echo "Recovering APP"
-            k8sHelmOps.rollback(CONTEXT, NAMESPACE, RELEASENAME)
+            k8sHelmOps.rollback(CONTEXT, DOCKER_IMAGE.split("/")[0], DOCKER_IMAGE.split("/")[0])
             throw err
           }
         }