Updated CI to run some things in parallel

This commit is contained in:
Jamie Curnow 2024-01-09 10:05:19 +10:00
parent e4ef095254
commit f7c87f63bd
No known key found for this signature in database
GPG Key ID: FFBB624C43388E9E

47
Jenkinsfile vendored
View File

@ -60,7 +60,9 @@ pipeline {
}
}
}
stage('Build and Test') {
stage('Builds') {
parallel {
stage('Project') {
steps {
script {
// Frontend and Backend
@ -84,6 +86,20 @@ pipeline {
}
}
}
stage('Docs') {
steps {
dir(path: 'docs') {
sh 'yarn install'
sh 'yarn build'
}
dir(path: 'docs/.vuepress/dist') {
sh 'tar -czf ../../docs.tgz *'
}
archiveArtifacts(artifacts: 'docs/docs.tgz', allowEmptyArchive: false)
}
}
}
}
stage('Integration Tests Sqlite') {
steps {
// Bring up a stack
@ -140,25 +156,6 @@ pipeline {
}
}
}
stage('Docs') {
when {
not {
equals expected: 'UNSTABLE', actual: currentBuild.result
}
}
steps {
dir(path: 'docs') {
sh 'yarn install'
sh 'yarn build'
}
dir(path: 'docs/.vuepress/dist') {
sh 'tar -czf ../../docs.tgz *'
}
archiveArtifacts(artifacts: 'docs/docs.tgz', allowEmptyArchive: false)
}
}
stage('MultiArch Build') {
when {
not {
@ -172,9 +169,9 @@ pipeline {
}
}
}
stage('Docs Deploy') {
stage('Docs / Comment') {
parallel {
stage('Master') {
stage('Master Docs') {
when {
allOf {
branch 'master'
@ -187,7 +184,7 @@ pipeline {
npmDocsReleaseMaster()
}
}
stage('Develop') {
stage('Develop Docs') {
when {
allOf {
branch 'develop'
@ -200,8 +197,6 @@ pipeline {
npmDocsReleaseDevelop()
}
}
}
}
stage('PR Comment') {
when {
allOf {
@ -218,6 +213,8 @@ pipeline {
}
}
}
}
}
post {
always {
sh 'docker-compose down --remove-orphans --volumes -t 30'