update gitea Jenkins file

add Jenkinsfile to sslproxy and add metrics.xai-corp.net.conf
This commit is contained in:
2018-10-28 22:53:46 -04:00
parent d8c685ccad
commit ce98660502
4 changed files with 39 additions and 19 deletions

View File

@@ -0,0 +1,35 @@
node('docker') {
def app_name = 'sslproxy'
def app_port = '80'
def workdir = 'dockerfiles/services/sslproxy'
stage('prepare') {
git credentialsId: 'f1f58215-c789-44a2-9b72-50e4425cb061', url: 'ssh://git@git.xai-corp.net:10022/xai-corp.net/provisioning.git'
sh 'ls'
}
stage('build') {
dir(workdir) {
sh """
docker-compose -f docker-compose.yml build
"""
sh "DOCKER_HOST=dkhost:2376 docker-compose -f docker-compose-prod.yml pull"
}
}
stage('deploy') {
dir(workdir) {
sh """
docker stack deploy --with-registry-auth --prune -c docker-compose-prod.yml sslproxy
docker service update sslproxy_app
"""
}
}
stage('smoke tests') {
dir(workdir) {
sleep 10
sh "curl -If https://jenkins.xai-corp.net/metrics/ejkxeVI-iKLy968ji9AnfYmOHGIh1kYd3gA500JqrRxzTeenT06ynR5Dqo0CQplO/healthcheck"
}
}
}