This commit is contained in:
parent
b166db12a4
commit
aa9b3fa9ba
9
Jenkinsfile
vendored
9
Jenkinsfile
vendored
@ -1,16 +1,13 @@
|
|||||||
pipeline {
|
pipeline {
|
||||||
environment {
|
environment {
|
||||||
registry = 'jcabillot/jenkins-wdocker'
|
registry = 'https://registry.hub.docker.com'
|
||||||
registryCredential = 'dockerhub_jcabillot'
|
registryCredential = 'dockerhub_jcabillot'
|
||||||
dockerImage = ''
|
dockerImage = 'jcabillot/jenkins-wdocker'
|
||||||
}
|
}
|
||||||
|
|
||||||
agent any
|
|
||||||
|
|
||||||
stages {
|
stages {
|
||||||
stage('Clone repository') {
|
stage('Clone repository') {
|
||||||
steps{
|
steps{
|
||||||
/* Let's make sure we have the repository cloned to our workspace */
|
|
||||||
checkout scm
|
checkout scm
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -24,7 +21,7 @@ pipeline {
|
|||||||
stage('Deploy Image') {
|
stage('Deploy Image') {
|
||||||
steps{
|
steps{
|
||||||
script {
|
script {
|
||||||
withDockerRegistry(url: 'https://registry.hub.docker.com', credentialsId: 'docker-hub-credentials') {
|
withDockerRegistry(url: 'https://registry.hub.docker.com', credentialsId: 'dockerhub_jcabillot') {
|
||||||
sh 'docker push jcabillot/jenkins-wdocker'
|
sh 'docker push jcabillot/jenkins-wdocker'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user