summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Péters <fpeters@entrouvert.com>2019-09-30 13:31:36 (GMT)
committerFrédéric Péters <fpeters@entrouvert.com>2019-09-30 13:31:36 (GMT)
commit4b4897f7e4874bc0240b57e0eedd1e1f6ac25335 (patch)
tree6f05e02a8ee47f348c7e9891a00f2b2848c9f2c6
parentcd396cddb233873586f18ecb0bf89ccce3c3571c (diff)
downloadeobuilder-4b4897f7e4874bc0240b57e0eedd1e1f6ac25335.zip
eobuilder-4b4897f7e4874bc0240b57e0eedd1e1f6ac25335.tar.gz
eobuilder-4b4897f7e4874bc0240b57e0eedd1e1f6ac25335.tar.bz2
add Jenkinsfile
-rw-r--r--Jenkinsfile29
1 files changed, 29 insertions, 0 deletions
diff --git a/Jenkinsfile b/Jenkinsfile
new file mode 100644
index 0000000..3666d71
--- /dev/null
+++ b/Jenkinsfile
@@ -0,0 +1,29 @@
+@Library('eo-jenkins-lib@master') import eo.Utils
+
+pipeline {
+ agent any
+ stages {
+ stage('Packaging') {
+ steps {
+ script {
+ if (env.JOB_NAME == 'eobuilder' && env.GIT_BRANCH == 'origin/master') {
+ sh 'sudo -H -u eobuilder /usr/local/bin/eobuilder -d stretch eobuilder'
+ } else if (env.GIT_BRANCH.startsWith('hotfix/')) {
+ sh "sudo -H -u eobuilder /usr/local/bin/eobuilder -d stretch --branch ${env.GIT_BRANCH} --hotfix eobuilder"
+ }
+ }
+ }
+ }
+ }
+ post {
+ always {
+ script {
+ utils = new Utils()
+ utils.mail_notify(currentBuild, env, 'admin+jenkins-eobuilder@entrouvert.com')
+ }
+ }
+ success {
+ cleanWs()
+ }
+ }
+}