diff --git a/Jenkinsfile b/Jenkinsfile index 7d42a5490..e762305a8 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -19,5 +19,18 @@ pipeline { } } } - } + stage('Push Docker Image') { + when { + branch 'main' + } + steps { + script { + docker.withRegistry('https://registry.hub.docker.com', 'docker_hub_login') { + app.push("${env.BUILD_NUMBER}") + app.push("latest") + } + } + } + } } +}