CI: allow Elasticsearch status to be green or yellow

It has been seen to go green, so allow this.

Change-Id: Id86b95dbba3434b16f3d0c11485a0d8601833cbf
This commit is contained in:
Mark Goddard 2021-05-11 10:20:48 +01:00
parent 8815deda19
commit edc918313d

View File

@ -42,8 +42,9 @@ function check_elasticsearch {
if ! curl "${args[@]}" $ELASTICSEARCH_URL > $output_path; then
return 1
fi
# NOTE(mgoddard): Status is yellow because no indices have been created.
if ! grep '"status":"yellow"' $output_path >/dev/null; then
# NOTE(mgoddard): Status may be yellow because no indices have been
# created.
if ! grep -E '"status":"(green|yellow)"' $output_path >/dev/null; then
return 1
fi
}