reformat jenkinsfile again x5
This commit is contained in:
parent
bdc69a5dc0
commit
bf53db3524
38
Jenkinsfile
vendored
38
Jenkinsfile
vendored
@ -12,9 +12,7 @@ pipeline {
|
|||||||
}
|
}
|
||||||
stage('Build API & UI') {
|
stage('Build API & UI') {
|
||||||
parallel {
|
parallel {
|
||||||
stage('API Build Process') {
|
stage('Build API') {
|
||||||
stages {
|
|
||||||
stage('Start API') {
|
|
||||||
steps {
|
steps {
|
||||||
sh '''docker image prune -f
|
sh '''docker image prune -f
|
||||||
docker build --no-cache -t fbla-api .
|
docker build --no-cache -t fbla-api .
|
||||||
@ -23,31 +21,19 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Run Tests') {
|
stage('UI Web Build') {
|
||||||
steps {
|
|
||||||
sh '''dart pub install
|
|
||||||
dart run ./test/fbla_api_test.dart'''
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('UI Build Process') {
|
|
||||||
stages {
|
|
||||||
stage('Build') {
|
|
||||||
parallel {
|
|
||||||
stage('Web Build') {
|
|
||||||
steps {
|
steps {
|
||||||
sh 'flutter build web --release --base-href /fbla/'
|
sh 'flutter build web --release --base-href /fbla/'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Build Linux') {
|
stage('UI Linux Build') {
|
||||||
steps {
|
steps {
|
||||||
sh 'flutter build linux --release'
|
sh 'flutter build linux --release'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Build APK') {
|
stage('UI APK Build') {
|
||||||
steps {
|
steps {
|
||||||
sh 'flutter build apk --release'
|
sh 'flutter build apk --release'
|
||||||
}
|
}
|
||||||
@ -55,9 +41,16 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
stage('Deploy and Save') {
|
stage('Deploy and Save') {
|
||||||
parallel {
|
parallel {
|
||||||
stage('Deploy Web Local') {
|
stage('Run API Tests') {
|
||||||
|
steps {
|
||||||
|
sh '''dart pub install
|
||||||
|
dart run ./test/fbla_api_test.dart'''
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Deploy Local Web UI') {
|
||||||
steps {
|
steps {
|
||||||
script {
|
script {
|
||||||
def remote = [
|
def remote = [
|
||||||
@ -110,10 +103,7 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
stage('Deploy Remote Web UI') {
|
||||||
}
|
|
||||||
|
|
||||||
stage('Deploy Remote') {
|
|
||||||
when {
|
when {
|
||||||
expression {
|
expression {
|
||||||
env.BRANCH_NAME == 'main'
|
env.BRANCH_NAME == 'main'
|
||||||
@ -140,5 +130,3 @@ pipeline {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue
Block a user