From 38b4fa38dd7514211e8ebd235f0ce78280025f27 Mon Sep 17 00:00:00 2001 From: Eldar Tursunbaev Date: Wed, 30 Jan 2019 11:00:50 +0600 Subject: [PATCH 1/2] return 444 --- debian/tree/nginx/nginx.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/debian/tree/nginx/nginx.conf b/debian/tree/nginx/nginx.conf index e20abf0..cb6a207 100644 --- a/debian/tree/nginx/nginx.conf +++ b/debian/tree/nginx/nginx.conf @@ -40,12 +40,12 @@ http { server { - server_name _; + server_name ""; listen 80 default_server; listen 443 ssl default_server; ssl_certificate /etc/ssl/certs/ssl-cert-snakeoil.pem; ssl_certificate_key /etc/ssl/private/ssl-cert-snakeoil.key; - return 404; # or whatever + return 444; # or whatever } server { From 89308c64b5842dca75a8d5d563e8b84cecd43767 Mon Sep 17 00:00:00 2001 From: Eldar Tursunbaev Date: Wed, 30 Jan 2019 11:05:10 +0600 Subject: [PATCH 2/2] mattermost notification and nginx --- Jenkinsfile | 6 ++---- debian/tree/nginx/nginx.conf | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9bb6adb..7d4057d 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -93,10 +93,8 @@ def notifyBuild(String buildStatus = 'STARTED', String details = '') { colorCode = '#FF0000' summary = "${subject} (${env.BUILD_URL})${details}" } - // Get token - def slackToken = getSlackToken('sysnet') - // Send notifications - slackSend (color: colorCode, message: summary, teamDomain: 'optdyn', token: "${slackToken}") + def mattermost_rest = "https://mm.optdyn.com/hooks/k1ujhg8xwigupxjzqbwzpgdp3h" + mattermostSend(color: colorCode, icon: "https://jenkins.io/images/logos/jenkins/jenkins.png", message: summary, channel: "#sysnet-bots", endpoint: "${mattermost_rest}" ) } // get slack token from global jenkins credentials store diff --git a/debian/tree/nginx/nginx.conf b/debian/tree/nginx/nginx.conf index cb6a207..678ecd7 100644 --- a/debian/tree/nginx/nginx.conf +++ b/debian/tree/nginx/nginx.conf @@ -40,7 +40,7 @@ http { server { - server_name ""; + server_name _; listen 80 default_server; listen 443 ssl default_server; ssl_certificate /etc/ssl/certs/ssl-cert-snakeoil.pem;