card-jong-fe/Jenkinsfile

31 lines
760 B
Plaintext
Raw Normal View History

2024-05-08 13:47:09 +00:00
pipeline {
agent any
stages {
stage("Populate env") {
steps {
sh 'rm .env || true'
sh 'echo VITE_BACKEND_URL=https://rimajon2.araozu.dev>>.env'
sh 'echo VITE_WS_URL=wss://rimajon2.araozu.dev>>.env'
}
}
stage('Build') {
agent {
docker {
2024-05-08 13:51:16 +00:00
image "gplane/pnpm"
2024-05-08 13:47:09 +00:00
reuseNode true
}
}
steps {
sh 'pnpm i'
sh 'pnpm build'
}
}
stage('Deploy') {
steps {
sh 'rm -rf /var/www/rimajon2/*'
sh 'cp -r ./dist/* /var/www/rimajon2/'
}
}
}
}