From 3f843a90c56690a59c7f15a3c4666f027399e85e Mon Sep 17 00:00:00 2001 From: me Date: Sat, 28 Feb 2026 08:55:36 +0300 Subject: [PATCH] update Jenkinsfile --- Jenkinsfile | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9872cb7..ed3f514 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,27 +1,16 @@ pipeline { agent any - - environment { - DEPLOY_PATH = '/var/www/fymio.us' - } - stages { stage('Deploy') { steps { - sh ''' - scp -o StrictHostKeyChecking=no index.html root@172.17.0.1:${DEPLOY_PATH}/ - scp -o StrictHostKeyChecking=no -r congrats/ root@172.17.0.1:${DEPLOY_PATH}/ - ''' + sshagent(['vps-ssh-key']) { + sh 'scp -o StrictHostKeyChecking=no index.html root@172.17.0.1:/var/www/fymio.us/' + } } } } - post { - success { - echo 'Deployment successful! Visit https://fymio.us' - } - failure { - echo 'Deployment failed!' - } + failure { echo 'Deployment failed!' } + success { echo 'Deployment successful!' } } }