2022-01-19 22:53:16 -06:00
|
|
|
pipeline {
|
|
|
|
agent any
|
|
|
|
stages {
|
2022-05-11 17:33:24 -05:00
|
|
|
stage ("install") {
|
|
|
|
steps {
|
2022-05-11 17:36:39 -05:00
|
|
|
nodejs("System") {
|
|
|
|
sh "npm install"
|
|
|
|
}
|
2022-05-11 17:33:24 -05:00
|
|
|
}
|
|
|
|
}
|
2022-05-11 17:46:51 -05:00
|
|
|
stage ("test") {
|
|
|
|
steps {
|
|
|
|
nodejs("System") {
|
|
|
|
sh "npm run test"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-01-19 22:53:16 -06:00
|
|
|
stage ("build") {
|
|
|
|
steps {
|
2022-05-11 17:36:39 -05:00
|
|
|
nodejs("System") {
|
2022-01-19 22:53:16 -06:00
|
|
|
sh "npm run build"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2022-01-20 00:16:18 -06:00
|
|
|
stage ("deploy") {
|
|
|
|
when {
|
|
|
|
branch '**/master'
|
|
|
|
}
|
|
|
|
steps {
|
2022-05-11 23:50:49 -05:00
|
|
|
sshagent(['34337c34-a538-42c4-8caf-66161bbc8044']) {
|
2022-05-11 21:59:02 -05:00
|
|
|
sh "scp -r dist/** www-data@sys.reslate.xyz:/srv/www/ent.sys.reslate.xyz"
|
|
|
|
}
|
2022-01-20 00:16:18 -06:00
|
|
|
}
|
|
|
|
}
|
2022-01-19 22:53:16 -06:00
|
|
|
}
|
|
|
|
}
|