Владимир Томишинец 5 år sedan
förälder
incheckning
afc151b269
1 ändrade filer med 7 tillägg och 4 borttagningar
  1. 7 4
      jenkinsfile.get.and.sync.dict

+ 7 - 4
jenkinsfile.get.and.sync.dict

@@ -76,11 +76,14 @@ pipeline {
     stages {
     stages {
         stage ("Git pull stack-deploy REPO") {
         stage ("Git pull stack-deploy REPO") {
             steps {
             steps {
-                withCredentials([sshUserPrivateKey(credentialsId: 'provision', keyFileVariable: 'GIT_SSH_KEY', passphraseVariable: '', usernameVariable: 'GIT_SSH_USERNAME')]) {
-                    sh '''GIT_SSH_COMMAND='ssh -i ${GIT_SSH_KEY} -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no' \
+                script {
+                    withCredentials([sshUserPrivateKey(credentialsId: 'provision', keyFileVariable: 'GIT_SSH_KEY', passphraseVariable: '', usernameVariable: 'GIT_SSH_USERNAME')]) {
+                        sh '''GIT_SSH_COMMAND='ssh -i ${GIT_SSH_KEY} -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no' \
                             git clone ${STACK_DEPLOY_REPO}
                             git clone ${STACK_DEPLOY_REPO}
-                       '''
-                TAG = sh (script: "cat ${WORKSPACE}/stack-deploy/tags/analis-wineservice.stable-version" , returnStdout: true).split('\n')
+                        '''
+                    }
+                    TAG = sh (script:  "cat ${WORKSPACE}/stack-deploy/tags/analis-wineservice.stable-version" , returnStdout: true).split('\n')
+                }
             }
             }
         }
         }
 /*        stage ("HELIX dictionaries") {
 /*        stage ("HELIX dictionaries") {