From 6c86599c0352c5d86025495c6379132a0db52934 Mon Sep 17 00:00:00 2001 From: "k.kedron" Date: Thu, 29 Aug 2019 17:05:58 +0200 Subject: Update ready-probe file Update ready-probe file to support the https mode. Issue-ID: SDC-2548 Signed-off-by: Krystian Kedron Change-Id: I78328d7575d202d1d241785e07fb57573ffe2739 --- .../cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb') diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb index fed19d1aa2..bad5f878dd 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb @@ -1,9 +1,6 @@ #!/bin/bash -<% if node[:disableHttp] -%> -health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' https://127.0.0.1:<%= @ssl_port %>/sdc1/rest/healthCheck) -<% else %> -health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' http://127.0.0.1:8181/sdc1/rest/healthCheck) -<% end -%> +health_Check_http_code=$(curl -k --max-time 5 -o /dev/null -w '%{http_code}' <%= @protocol %>://127.0.0.1:<%= @port %>/sdc1/rest/healthCheck) + if [[ "$health_Check_http_code" -eq 200 ]]; then exit 0 else -- cgit 1.2.3-korg