node { def app stage('Clone repository') { git branch: 'DRIP_3.0', url: 'https://github.com/skoulouzis/DRIP.git' } } node('docker') { stage('Clone repository on slave') { git branch: 'DRIP_3.0', url: 'https://github.com/skoulouzis/DRIP.git' } stage('Build image') { /* This builds the actual image; synonymous to * docker build on the command line */ sh "cd sure_tosca-flask-server" app = docker.build("sure-tosca/alogo53") } stage('Test image') { app.inside { sh 'echo "Tests passed"' } } stage('Push image') { //docker.withRegistry('https://registry.hub.docker.com', 'docker-hub') { // app.push("${env.BUILD_NUMBER}") // app.push("latest") //} } }