From 18e85bf1f5725d56a078fd8d607d0b9076a18f7d Mon Sep 17 00:00:00 2001 From: andrzej Date: Sat, 25 May 2024 11:20:08 +0200 Subject: [PATCH] add build and deploy steps --- Jenkinsfile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index e7e2a94..479aa08 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -2,10 +2,16 @@ pipeline { agent any stages { - stage('Do nothing') { - steps { - sh '/bin/true' + stage('build'){ + steps{ + sh 'npm install' + sh 'npm run build' } } + stage('deploy'){ + steps{ +sshPublisher(publishers: [sshPublisherDesc(configName: 'Demos', transfers: [sshTransfer(cleanRemote: false, excludes: '', execCommand: '', execTimeout: 120000, flatten: false, makeEmptyDirs: false, noDefaultExcludes: false, patternSeparator: '[, ]+', remoteDirectory: '/home/jenkins/ssh-uploads/calculator', remoteDirectorySDF: false, removePrefix: '', sourceFiles: 'build')], usePromotionTimestamp: false, useWorkspaceInPromotion: false, verbose: false)]) + + } } }