From c0c0056d724050ffb4cdd6e1d7d59b8cea63c6fc Mon Sep 17 00:00:00 2001 From: Dimitri B Date: Tue, 18 Jun 2024 18:29:44 +0200 Subject: [PATCH] Fix syntax error in elasticsearch healthcheck script --- elasticsearch/scripts/docker-healthcheck | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/elasticsearch/scripts/docker-healthcheck b/elasticsearch/scripts/docker-healthcheck index 6f0a223..9271053 100644 --- a/elasticsearch/scripts/docker-healthcheck +++ b/elasticsearch/scripts/docker-healthcheck @@ -3,7 +3,7 @@ set -eo pipefail host="$(hostname --ip-address || echo '127.0.0.1')" -if health="$(curl -fsSL "https://$ELASTIC_USERNAME:$ELASTIC_PASSWORD@$host:$ELASTICSEARCH_PORT/_cat/health?h=status" --insecure")"; then +if health="$(curl -fsSL "https://$ELASTIC_USERNAME:$ELASTIC_PASSWORD@$host:$ELASTICSEARCH_PORT/_cat/health?h=status" --insecure)"; then health="$(echo "$health" | sed -r 's/^[[:space:]]+|[[:space:]]+$//g')" # trim whitespace (otherwise we'll have "green ") if [ "$health" = 'green' ] || [ "$health" = "yellow" ]; then exit 0