Merge "Add healthchecks for barbican containers"

This commit is contained in:
Zuul 2018-02-13 12:39:57 +00:00 committed by Gerrit Code Review
commit 09c28480df
4 changed files with 52 additions and 0 deletions

View File

@ -134,6 +134,24 @@ RUN mkdir -p /openstack && \
chmod a+rx /openstack/healthcheck
{% endblock %}
{% block barbican_api_footer %}
RUN mkdir -p /openstack && \
ln -s /usr/share/openstack-tripleo-common/healthcheck/barbican-api /openstack/healthcheck && \
chmod a+rx /openstack/healthcheck
{% endblock %}
{% block barbican_keystone_listener_footer %}
RUN mkdir -p /openstack && \
ln -s /usr/share/openstack-tripleo-common/healthcheck/barbican-keystone-listener /openstack/healthcheck && \
chmod a+rx /openstack/healthcheck
{% endblock %}
{% block barbican_worker_footer %}
RUN mkdir -p /openstack && \
ln -s /usr/share/openstack-tripleo-common/healthcheck/barbican-worker /openstack/healthcheck && \
chmod a+rx /openstack/healthcheck
{% endblock %}
{% block ceilometer_central_footer %}
RUN mkdir -p /openstack && \
ln -s /usr/share/openstack-tripleo-common/healthcheck/ceilometer-agent-central /openstack/healthcheck && \

6
healthcheck/barbican-api Executable file
View File

@ -0,0 +1,6 @@
#!/bin/sh
. ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh
check_url=$(get_url_from_vhost /etc/httpd/conf.d/10-barbican_wsgi_main.conf)
healthcheck_curl ${check_url}

View File

@ -0,0 +1,14 @@
#!/bin/bash
. ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh
process='barbican-keystone-listener'
args="${@:-5671 5672}"
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"
exit 1
fi

14
healthcheck/barbican-worker Executable file
View File

@ -0,0 +1,14 @@
#!/bin/bash
. ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh
process='barbican-worker'
args="${@:-5671 5672}"
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"
exit 1
fi