diff Jenkinsfile @ 19:02c83c12d3d5

added jenkins build
author am@osimis.io
date Thu, 19 Jul 2018 15:04:00 +0200
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Jenkinsfile	Thu Jul 19 15:04:00 2018 +0200
@@ -0,0 +1,21 @@
+try {
+  node('docker') {
+    stage 'Retrieve sources'
+    deleteDir()
+    checkout scm
+
+    lock(resource: 'orthanc-authorization-plugin', inversePrecedence: false) {
+      stage 'Build Docker image & run unit tests'
+      sh 'scripts/ciBuildDockerImage.sh'
+    }
+    
+    withCredentials([[$class: 'AmazonWebServicesCredentialsBinding', credentialsId: 'aws-orthanc.osimis.io']]) {
+      stage 'Push Docker plugin to AWS'
+      sh 'scripts/ciPushToAws.sh ${BRANCH_NAME}'
+    }
+  }
+} 
+catch (e) {
+    slackSend color: '#FF0000', message: "${env.JOB_NAME} has failed ${env.JOB_URL}"
+    throw e
+} 
\ No newline at end of file