Update Jenkinsfile

Signed-off-by: prankumargrid <prankumar@griddynamics.com>
This commit is contained in:
prankumargrid 2025-04-25 11:35:01 +05:30 committed by GitHub
parent 4ce7ed9d3a
commit 8184261d41
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

4
Jenkinsfile vendored
View file

@ -54,8 +54,8 @@ pipeline{
def imageTag = env.BRANCH_NAME == 'main' ? 'latest' : GIT_COMMIT_SHORT
sh """
echo $DOCKER_PASSWORD | docker login -u $DOCKER_USERNAME --password-stdin $REGISTRY_URL
docker tag $REGISTRY_URL/$(IMAGE_NAME):${imageTag} $REGISTRY_URL/${targetRepo}/${IMAGE_NAME}:${imageTag}
docker push $REGISTRY_URL/${targetRepo}/${IMAGE_NAME}:${imageTag}
docker tag $REGISTRY_URL/$IMAGE_NAME:$imageTag $REGISTRY_URL/$targetRepo/$IMAGE_NAME:$imageTag
docker push $REGISTRY_URL/$targetRepo/$IMAGE_NAME:$imageTag
"""
}
}