openstack-helm-infra/rabbitmq/templates/bin/_rabbitmq-liveness.sh.tpl
Vasyl Saienko b591d3aa49 [rabbitmq] Update readiness/liveness commands
Use lightweigh rabbitmqctl ping command to check readiness and liveness probe.
check_port_connectivity - is not suatable for liveness as it does not check
  that instance of rabbitmq is actually running and we can authenticate.

Change-Id: I6f157e9aef3450dba1ad7e0cb19491a41f700bbc
2024-09-13 10:01:18 +00:00

24 lines
657 B
Smarty

#!/usr/bin/env bash
{{/*
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/}}
set -e
if [ -f /tmp/rabbit-disable-liveness-probe ]; then
exit 0
else
exec rabbitmqctl ping
fi