From 6afe83f274b75f1ec37e6560cb0b0638155dac8f Mon Sep 17 00:00:00 2001 From: Patrik Greco Date: Thu, 25 Jul 2019 09:19:28 +0200 Subject: [PATCH] Add check to install unzip if needed This is mainly needed for newer docker images that seems to be missing the unzip utility --- scripts/setup-elasticsearch.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/setup-elasticsearch.sh b/scripts/setup-elasticsearch.sh index 13830e8..35af48b 100755 --- a/scripts/setup-elasticsearch.sh +++ b/scripts/setup-elasticsearch.sh @@ -37,6 +37,10 @@ if [[ -d /usr/share/elasticsearch/bin/x-pack ]]; then echo "CA directory exists, removing..." rm -rf /config/ssl/ca fi + echo "Install unzip if needed..." + if ! command -v unzip &>/dev/null; then + yum -qy install unzip + fi echo "Unzip ca files..." unzip /config/ssl/docker-cluster-ca.zip -d /config/ssl