diff --git a/Jenkinsfile b/Jenkinsfile index afee9ac..5485e4d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,9 +13,18 @@ pipeline { } } + stage('deploy') { + def remote = [:] + remote.name = "node-1" + remote.host = "130.120.3.231" + remote.allowAnyHosts = true + steps { - sh 'echo deploy' + withCredentials([sshUserPrivateKey(credentialsId: 'e41b57a4-436a-4617-817c-9e3f25a8a47f', keyFileVariable: 'identity', passphraseVariable: '', usernameVariable: 'userName')]) { + sshCommand remote: remote, command: 'docker stop adminapi' + } + sh 'echo deploy' } } }