forked from verdnatura/salix-front
refs #6797 feat(jenkins) deploy dev-lilium
This commit is contained in:
parent
df2bb66538
commit
87c5e6fe60
|
@ -49,6 +49,9 @@ pipeline {
|
|||
options {
|
||||
disableConcurrentBuilds()
|
||||
}
|
||||
tools {
|
||||
nodejs 'node-v18'
|
||||
}
|
||||
environment {
|
||||
PROJECT_NAME = 'lilium'
|
||||
STACK_NAME = "${env.PROJECT_NAME}-${env.BRANCH_NAME}"
|
||||
|
@ -59,11 +62,9 @@ pipeline {
|
|||
NODE_ENV = ""
|
||||
}
|
||||
steps {
|
||||
nodejs('node-v18') {
|
||||
sh 'bun install --no-audit --prefer-offline'
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Test') {
|
||||
when {
|
||||
expression { !PROTECTED_BRANCH }
|
||||
|
@ -74,13 +75,11 @@ pipeline {
|
|||
parallel {
|
||||
stage('Frontend') {
|
||||
steps {
|
||||
nodejs('node-v18') {
|
||||
sh 'bun run test:unit:ci'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stage('Build') {
|
||||
when {
|
||||
expression { PROTECTED_BRANCH }
|
||||
|
@ -89,9 +88,7 @@ pipeline {
|
|||
CREDENTIALS = credentials('docker-registry')
|
||||
}
|
||||
steps {
|
||||
nodejs('node-v18') {
|
||||
sh 'quasar build'
|
||||
}
|
||||
// dockerBuild()
|
||||
}
|
||||
}
|
||||
|
@ -103,6 +100,10 @@ pipeline {
|
|||
DOCKER_HOST = "${env.SWARM_HOST}"
|
||||
}
|
||||
steps {
|
||||
script {
|
||||
def packageJson = readJSON file: 'package.json'
|
||||
env.VERSION = packageJson.version
|
||||
}
|
||||
sh "docker stack deploy --with-registry-auth --compose-file docker-compose.yml ${env.STACK_NAME}"
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue