Update Jenkinsfile
This commit is contained in:
parent
f400932f40
commit
15975d8582
3
Jenkinsfile
vendored
3
Jenkinsfile
vendored
@ -32,7 +32,8 @@ node {
|
|||||||
* First, the incremental build number from Jenkins
|
* First, the incremental build number from Jenkins
|
||||||
* Second, the 'latest' tag.
|
* Second, the 'latest' tag.
|
||||||
* Pushing multiple tags is cheap, as all the layers are reused. */
|
* Pushing multiple tags is cheap, as all the layers are reused. */
|
||||||
docker.withRegistry('https://docker.io', 'docker-hub-credentials') {
|
withCredentials([[$class: 'UsernamePasswordMultiBinding', credentialsId: 'docker-hub-credentials', usernameVariable: 'USERNAME', passwordVariable: 'PASSWORD']]) {
|
||||||
|
sh 'docker login -u $USERNAME -p $PASSWORD
|
||||||
script {
|
script {
|
||||||
if (env.BRANCH_NAME == 'master') {
|
if (env.BRANCH_NAME == 'master') {
|
||||||
app.push()
|
app.push()
|
||||||
|
Loading…
Reference in New Issue
Block a user