Files
sheetless/Jenkinsfile

59 lines
1.9 KiB
Groovy

pipeline {
agent {
node {
label 'devenv'
}
}
triggers {
pollSCM('H/10 * * * *')
}
stages {
stage('Test devenv') {
steps {
sh 'devenv test'
}
}
stage('Parallel Build and Deploy') {
parallel {
stage('Android') {
stages {
stage('Build') {
steps {
sh 'devenv shell flutter build apk'
}
}
stage('Deploy') {
steps {
echo 'Push to f-droid not yet implemented, archiving instead'
archiveArtifacts artifacts: 'build/app/outputs/apk/release/app-release.apk'
}
}
}
}
stage('Web') {
stages {
stage('Build') {
steps {
sh 'devenv shell flutter build web --release'
sh 'docker build -t harbor.julian-mutter.de/sheetless/sheetless-frontend .'
}
}
stage('Deploy') {
steps {
withDockerRegistry([credentialsId: 'harbor-login-julian', url: 'https://harbor.julian-mutter.de']) {
sh 'docker push harbor.julian-mutter.de/sheetless/sheetless-frontend'
}
}
}
}
}
}
}
}
post {
always {
step([$class: 'Mailer', notifyEveryUnstableBuild: true, recipients: emailextrecipients([developers(), requestor()])])
}
}
}