From b890ade4064fc3d2f93416af1c9dd27113bb492d Mon Sep 17 00:00:00 2001 From: Joan Sanchez Date: Thu, 7 Feb 2019 08:03:23 +0100 Subject: [PATCH 1/2] docker scale 2 back containers --- Jenkinsfile | 4 ++-- front/nginx.conf | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 3a4195256..75a6bd384 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -101,7 +101,7 @@ pipeline { steps { withCredentials([dockerCert(credentialsId: 'docker', variable: 'DOCKER_CERT_PATH')]) { sh 'docker-compose pull' - sh 'docker-compose up -d --scale back=3' + sh 'docker-compose up -d --scale back=2' } } } @@ -112,7 +112,7 @@ pipeline { steps { withCredentials([dockerCert(credentialsId: 'docker', variable: 'DOCKER_CERT_PATH')]) { sh 'docker-compose pull' - sh 'docker-compose up -d --scale back=3' + sh 'docker-compose up -d --scale back=2' } } } diff --git a/front/nginx.conf b/front/nginx.conf index b9e0d5c7c..d6205af1e 100644 --- a/front/nginx.conf +++ b/front/nginx.conf @@ -2,7 +2,6 @@ upstream back { server back_1:3000; server back_2:3000; - server back_3:3000; } server { listen 80 default_server; From f67aee43bd1ee8a003c57f92d563b65fb4a21862 Mon Sep 17 00:00:00 2001 From: Joan Sanchez Date: Thu, 7 Feb 2019 08:39:07 +0100 Subject: [PATCH 2/2] open PDF as preview on browser --- print/lib/router.js | 1 - 1 file changed, 1 deletion(-) diff --git a/print/lib/router.js b/print/lib/router.js index 69b02b702..59e8a5b74 100644 --- a/print/lib/router.js +++ b/print/lib/router.js @@ -16,7 +16,6 @@ module.exports = app => { app.get(`/api/report/${name}`, (request, response, next) => { reportEngine.toPdf(name, request).then(stream => { - response.setHeader('Content-Disposition', `attachment; filename="${name}.pdf"`); response.setHeader('Content-type', 'application/pdf'); stream.pipe(response); }).catch(e => {