Debug Jenkins

This commit is contained in:
myrmidex 2025-07-13 21:55:03 +02:00
parent 9a8f8b770b
commit df34ebbc1f

19
Jenkinsfile vendored
View file

@ -4,7 +4,7 @@ pipeline {
environment {
REGISTRY = 'codeberg.org'
IMAGE_NAME = "${REGISTRY}/lvl0/incr"
DOCKER_CREDENTIALS_ID = 'codeberg-registry' // Jenkins credential ID
DOCKER_CREDENTIALS_ID = 'codeberg-registry' // Jenkins credentials ID
}
stages {
@ -34,4 +34,19 @@ pipeline {
stage('Push to Registry') {
steps {
echo "📤 Pushing Docker image: ${IMAGE_NAME}:${GIT_TAG}"
withCredentials([usernamePassword(credentialsId: "${DOCKER_CREDENTIALS_ID}", usernam]()
withCredentials([
usernamePassword(
credentialsId: DOCKER_CREDENTIALS_ID,
usernameVariable: 'USERNAME',
passwordVariable: 'PASSWORD'
)
]) {
sh """
echo "${PASSWORD}" | docker login ${REGISTRY} -u "${USERNAME}" --password-stdin
docker push ${IMAGE_NAME}:${GIT_TAG}
"""
}
}
}
}
}