aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/ready-probe.sh.erb
blob: 35aef8ea17ee7386efdff49ab94f3648f2d98450 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/bash
health_Check_http_code=$(curl -k --max-time 5 -o /dev/null -w '%{http_code}' <%= @protocol %>://127.0.0.1:<%= @port %>/sdc2/rest/healthCheck)

if [[ "$health_Check_http_code" -eq 200 ]]; then
   exit 0
else
   exit $health_Check_http_code
fi