This commit is contained in:
parent
0fe9373c56
commit
b166db12a4
10
Jenkinsfile
vendored
10
Jenkinsfile
vendored
@ -17,18 +17,16 @@ pipeline {
|
|||||||
|
|
||||||
stage('Build image') {
|
stage('Build image') {
|
||||||
steps{
|
steps{
|
||||||
/* This builds the actual image; synonymous to
|
sh "docker build -t jcabillot/jenkins-wdocker ."
|
||||||
* docker build on the command line */
|
|
||||||
app = docker.build("jcabillot/jenkins-wdocker")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
stage('Deploy Image') {
|
stage('Deploy Image') {
|
||||||
steps{
|
steps{
|
||||||
script {
|
script {
|
||||||
docker.withRegistry('https://registry.hub.docker.com', 'docker-hub-credentials') {
|
withDockerRegistry(url: 'https://registry.hub.docker.com', credentialsId: 'docker-hub-credentials') {
|
||||||
app.push("latest")
|
sh 'docker push jcabillot/jenkins-wdocker'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user