| #!/usr/bin/env groovy | |
| pipeline { | |
| agent any | |
| options { | |
| ansiColor('xterm') | |
| timestamps() | |
| } | |
| libraries { | |
| lib("jenkins-library@master") | |
| } | |
| stages { | |
| stage('Maven Build') { | |
| steps { | |
| sh 'mvn clean package' | |
| } | |
| } | |
| stage('Docker Build') { | |
| steps { | |
| script { | |
| buildApp{ | |
| app = 'foo' | |
| } | |
| } | |
| } | |
| } | |
| stage('Test') { | |
| steps { | |
| runEndToEnd("foo") | |
| } | |
| } | |
| stage('Deploy') { | |
| when { | |
| branch 'master' | |
| } | |
| steps { | |
| deploy("foo", "test") | |
| } | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment