From c4bf16c26fce9dbf0ccb11adc0215661c3117a7e Mon Sep 17 00:00:00 2001 From: Helder Oliveira Date: Fri, 20 Oct 2023 20:23:06 +0100 Subject: [PATCH] =?UTF-8?q?refactor:=20=F0=9F=92=A1=20add=20healthcheck=20?= =?UTF-8?q?fallback=20for=20custom=20setups?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/healthcheck | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/healthcheck b/scripts/healthcheck index b43570a..eac9966 100644 --- a/scripts/healthcheck +++ b/scripts/healthcheck @@ -201,6 +201,18 @@ warningCount=0 ((healthIssueCount++)) fi + if ! curl -s -w "\n" localhost:4230/health | grep -iq 'running and staked'; then + echo "⚠️ WARNING: Failed to get a response from localhost:4230/health. The node seems to be offline (not running), if you are participating in testnet, then read the instructions in https://docs.fleek.network/docs/node/testnet-onboarding, to run successfully!" + + ((warningCount++)) + ((healthIssueCount++)) + else + echo "✅ The localhost:4230/health is okay" + fi + else + echo "⚠️ WARNING: Your setup seems to be custom, e.g. running quickly with Docker or Lightning CLI, in any of this cases without Systemd service wrapper, etc. Be aware the tools provided via get.fleek.network are meant for recommeded setups via docs or tools." + echo + if ! curl -s -w "\n" localhost:4230/health | grep -iq 'running and staked'; then echo "⚠️ WARNING: Failed to get a response from localhost:4230/health. The node seems to be offline (not running), if you are participating in testnet, then read the instructions in https://docs.fleek.network/docs/node/testnet-onboarding, to run successfully!"