From 414c853ed5fc8bbe3dfc7e63b3b4a3f202362cae Mon Sep 17 00:00:00 2001 From: MOREY Thibault <thibault.morey3@etu.univ-lorraine.fr> Date: Thu, 18 Feb 2021 09:49:18 +0000 Subject: [PATCH] Update Jenkinsfile --- Jenkinsfile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 34dd43c..d1e2088 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -1,5 +1,7 @@ node{ def app + def registryProject='127.0.0.1:8083' + def image="${registryProject}:version-${env.BUILD_ID}" stage('Clone') { checkout scm @@ -11,12 +13,14 @@ node{ stage('Test image') { docker.image('debian:buster').withRun('-p 81:81') { c -> - - + sh 'docker ps' } stage('Push on repo nexus') - docker push 127.0.0.1:8082/debian:buster + docker.withRegistry('127.0.0.1:8083','reg1'){ + img.push 'latest' + img.push + } } } \ No newline at end of file -- GitLab