Permalink
Jul 5, 2016
Aug 4, 2016
Jul 14, 2016
Jul 5, 2016
Newer
100644
42 lines (34 sloc)
1.04 KB

1
node {
2
stage 'Checkout'
3
4
checkout scm
5

6
stage 'BUILD: Base'
7
8
try{
9
// Build Base Image
10
dir('bin') {
11
sh './build.sh &> debug'
12
}
13
// Build Base Image
14
// sh './build_image.sh &> debug'
15
// Run Base Container
16
// sh 'bin/run.sh'
17
} catch(error) {
18
def error_details = readFile('./bin/debug');
19
def message = "BUILD ERROR: There was a problem building the Base Image. \n\n ${error_details}"
20
sh "rm -f ./bin/debug"
21
handleError(message)
22
}
23
24
stage 'TEST: Base'
25

30
docker.withRegistry('https://registry.hub.docker.com/', 'dockerhub-bigfleet') {
31
def baseImg = docker.build('bigfleet/centos7base')
32
baseImg.push('latest')
33
}

35