fix: install script drops an error

This commit is contained in:
Andras Bacsai 2023-09-28 13:05:17 +02:00
parent df4ecd47a7
commit cdb6964b0b

View File

@ -72,14 +72,21 @@ cat >/etc/docker/daemon.json.coolify <<EOL
EOL
cat <<<$(jq . /etc/docker/daemon.json.coolify) >/etc/docker/daemon.json.coolify
cat <<<$(jq -s '.[0] * .[1]' /etc/docker/daemon.json /etc/docker/daemon.json.coolify) >/etc/docker/daemon.json
DIFF=$(diff <(jq --sort-keys . /etc/docker/daemon.json) <(jq --sort-keys . /etc/docker/daemon.json.original-$DATE))
if [ "$DIFF" != "" ]; then
if [ -s /etc/docker/daemon.json.original-$DATE ]; then
DIFF=$(diff <(jq --sort-keys . /etc/docker/daemon.json) <(jq --sort-keys . /etc/docker/daemon.json.original-$DATE))
if [ "$DIFF" != "" ]; then
echo "Docker configuration updated, restart docker daemon..."
systemctl restart docker
else
else
echo "Docker configuration is up to date."
fi
else
echo "Docker configuration updated, restart docker daemon..."
systemctl restart docker
fi
echo -e "-------------"
mkdir -p /data/coolify/ssh/keys