From a2aa850632f7c1adf08ae596e764df7b9541a598 Mon Sep 17 00:00:00 2001 From: Karol Wypchlo Date: Mon, 12 Jul 2021 14:49:53 +0200 Subject: [PATCH] improve health check reliability --- setup-scripts/health-checker.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/setup-scripts/health-checker.py b/setup-scripts/health-checker.py index 5656927c..c4af5f39 100755 --- a/setup-scripts/health-checker.py +++ b/setup-scripts/health-checker.py @@ -148,15 +148,15 @@ async def check_health(): res = requests.get(endpoint + "/health-check", verify=False) json_check = res.json() - res = requests.get(endpoint + "/health-check/critical", verify=False).json() + res = requests.get(endpoint + "/health-check/critical", verify=False) json_critical = res.json() - res = requests.get(endpoint + "/health-check/extended", verify=False).json() + res = requests.get(endpoint + "/health-check/extended", verify=False) json_extended = res.json() except: message = traceback.format_exc() message += "\n" + "Request url: " + res.url if res.url else "-" - message += "\n" + "Status code: " + res.status_code if res.status_code else "-" + message += "\n" + "Status code: " + str(res.status_code) if res.status_code else "-" message += "\n" + "Response body: " + res.text if res.text else "-" return await send_msg( client, "Failed to run health checks!", file=message, force_notify=True