51 lines
1.0 KiB
Groovy
51 lines
1.0 KiB
Groovy
pipeline {
|
|
agent {
|
|
label 'pi501.in.thelinuxpro.net'
|
|
}
|
|
|
|
stages {
|
|
stage("verify tooling") {
|
|
steps {
|
|
sh '''
|
|
docker version
|
|
docker info
|
|
docker compose version
|
|
'''
|
|
}
|
|
}
|
|
|
|
# stage("Jekyll Build") {
|
|
# steps {
|
|
# script {
|
|
# sh 'JEKYLL_ENV=production bundle exec jekyll build'
|
|
# }
|
|
# }
|
|
# }
|
|
|
|
stage("Build Containers and push to registry") {
|
|
steps {
|
|
script {
|
|
sh 'docker build -t docker-registry1.in.thelinuxpro.net:5000/sites/kameronkenny.com:0.0.1 . --push'
|
|
}
|
|
}
|
|
}
|
|
|
|
stage("Tag image as latest") {
|
|
steps {
|
|
script {
|
|
sh 'docker tag docker-registry1.in.thelinuxpro.net:5000/sites/kameronkenny.com:0.0.1 docker-registry1.in.thelinuxpro.net:5000/sites/kameronkenny.com:latest'
|
|
}
|
|
}
|
|
}
|
|
|
|
stage("push latest tag") {
|
|
steps {
|
|
script {
|
|
sh 'docker image push docker-registry1.in.thelinuxpro.net:5000/sites/kameronkenny.com:latest'
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|