diff --git a/Jenkinsfile b/Jenkinsfile index 531037dc0..1fec50052 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -16,5 +16,36 @@ pipeline { } } } + stage('Build Docker images') { + when { + expression { + return GIT_BRANCH in ['master', 'SHIBUI-794'] + } + } + steps { + sh '''./gradlew docker + ''' + } + } + stage('Deploy') { + when { + expression { + return GIT_BRANCH in ['master', 'SHIBUI-794'] + } + } + steps { + sh ''' + docker run unicon/shibui + ''' + } + } + } + post { + failure { + step([$class: 'Mailer', notifyEveryUnstableBuild: true, recipients: emailextrecipients([[$class: 'CulpritsRecipientProvider'], [$class: 'RequesterRecipientProvider']])]) + } + success { + emailext body: '''${SCRIPT, template="groovy-text.template"}''', recipientProviders: [[$class: 'DevelopersRecipientProvider'], [$class: 'RequesterRecipientProvider']], subject: '[SHIBUI] Build Success' + } } } \ No newline at end of file