#814 Docker deploy fixes
This commit is contained in:
parent
4305c35946
commit
1c08ad6e2e
|
@ -11,9 +11,7 @@ switch (env.BRANCH_NAME) {
|
||||||
|
|
||||||
node {
|
node {
|
||||||
stage ('Print environment variables') {
|
stage ('Print environment variables') {
|
||||||
echo "Branch: ${env.BRANCH_NAME}"
|
echo "Build number: ${env.BUILD_NUMBER}, Node environment: ${env.NODE_ENV}"
|
||||||
echo "Build number: ${env.BUILD_NUMBER}"
|
|
||||||
echo "Node environment: ${env.NODE_ENV}"
|
|
||||||
}
|
}
|
||||||
stage ('Checkout') {
|
stage ('Checkout') {
|
||||||
checkout scm
|
checkout scm
|
||||||
|
@ -31,15 +29,13 @@ node {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage ('Docker deployment') {
|
stage ('Docker deployment') {
|
||||||
withCredentials([dockerCert(credentialsId: 'docker', variable: 'DOCKER_CERT_PATH')]) {
|
env.COMPOSE_HTTP_TIMEOUT = 300
|
||||||
environment {
|
env.COMPOSE_PROJECT_NAME = 'salix'
|
||||||
COMPOSE_HTTP_TIMEOUT = 300
|
env.DOCKER_TLS_VERIFY = 1
|
||||||
COMPOSE_PROJECT_NAME = 'salix'
|
|
||||||
DOCKER_TLS_VERIFY = 1
|
|
||||||
}
|
|
||||||
|
|
||||||
sh "docker-compose build"
|
sh "docker-compose build"
|
||||||
|
|
||||||
|
withCredentials([dockerCert(credentialsId: 'docker', variable: 'DOCKER_CERT_PATH')]) {
|
||||||
env.DOCKER_HOST = 'tcp://vch2.verdnatura.es:2376';
|
env.DOCKER_HOST = 'tcp://vch2.verdnatura.es:2376';
|
||||||
sh "docker-compose up -d"
|
sh "docker-compose up -d"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue