diff --git a/healthcheck/octavia-api b/healthcheck/octavia-api new file mode 100755 index 000000000..4b619e24b --- /dev/null +++ b/healthcheck/octavia-api @@ -0,0 +1,13 @@ +#!/bin/sh + +. ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh + +bind_host=$(get_config_val /etc/octavia/octavia.conf api_settings bind_host 127.0.0.1) +bind_port=$(get_config_val /etc/octavia/octavia.conf api_settings bind_port 9876) + +# Add brackets if IPv6 +if [[ $bind_host =~ ":" ]]; then + bind_host="[${bind_host}]" +fi + +healthcheck_curl http://${bind_host}:${bind_port}/ diff --git a/healthcheck/octavia-health-manager b/healthcheck/octavia-health-manager index ac62e04f5..80aa9b41c 100755 --- a/healthcheck/octavia-health-manager +++ b/healthcheck/octavia-health-manager @@ -3,12 +3,12 @@ . ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh process='octavia-health-manager' -args="${@:-5671 5672}" +args="${@:-5555}" -if healthcheck_port $process $args; then +if healthcheck_listen $process $args; then exit 0 else ports=${args// /,} - echo "There is no $process process with opened RabbitMQ ports ($ports) running in the container" + echo "There is no $process process listening on ports $ports." exit 1 fi diff --git a/healthcheck/octavia-housekeeping b/healthcheck/octavia-housekeeping index 855b80055..3d8cdb3a4 100755 --- a/healthcheck/octavia-housekeeping +++ b/healthcheck/octavia-housekeeping @@ -3,12 +3,12 @@ . ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh process='octavia-housekeeping' -args="${@:-5671 5672}" +args="${@:-3306}" if healthcheck_port $process $args; then exit 0 else ports=${args// /,} - echo "There is no $process process with opened RabbitMQ ports ($ports) running in the container" + echo "Did not find $process process running and connected to MySQL via ports ($ports) in the container." exit 1 fi