jekyll_docker_image/Jenkinsfile

44 lines
856 B
Groovy

pipeline {
agent {
label 'pi501.in.thelinuxpro.net'
}
stages {
stage("verify tooling") {
steps {
sh '''
docker version
docker info
docker compose version
'''
}
}
stage("Build Containers and push to registry") {
steps {
script {
sh 'docker build -t docker-registry1.in.thelinuxpro.net:5000/tlp/tlp_jekyll:2024.07.01-1 . --push'
}
}
}
stage("Tag image as latest") {
steps {
script {
sh 'docker tag docker-registry1.in.thelinuxpro.net:5000/tlp/tlp_jekyll:2024.07.01-1 docker-registry1.in.thelinuxpro.net:5000/tlp/tlp_jekyll:latest'
}
}
}
stage("push latest tag") {
steps {
script {
sh 'docker image push docker-registry1.in.thelinuxpro.net:5000/tlp/tlp_jekyll:latest'
}
}
}
}
}