luhaowen 3 주 전
부모
커밋
a0711c2999
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      vars/deployJar.groovy

+ 1 - 1
vars/deployJar.groovy

@@ -21,7 +21,7 @@ def call(Map args = [:]) {
         sh "scp -o StrictHostKeyChecking=no ${jarPath} ${remoteHost}:${remoteJar}"
 
         /* 4. 启动新服务 */
-        sh '''ssh -o StrictHostKeyChecking=no ${remoteHost} "sh -c 'cd ${remotePath} && nohup java -jar ${jarName} --spring.profiles.active=${profile} > server.log 2>&1 &'" '''
+        sh """ssh -o StrictHostKeyChecking=no ${remoteHost} "sh -c 'cd ${remotePath} && nohup java -jar ${jarName} --spring.profiles.active=${profile} > server.log 2>&1 &'" """
 
         PrintMes("发布成功 ${jarName}", 'green')
     } catch (Exception e) {