mirror of
https://github.com/bunkerity/bunkerweb
synced 2026-05-24 09:28:37 +00:00
ping now working
This commit is contained in:
parent
c28387ec28
commit
f2bb7fda8f
3 changed files with 2 additions and 9 deletions
|
|
@ -8,7 +8,7 @@ def redis(**kwargs):
|
|||
ping = {"ping_status": "error"}
|
||||
|
||||
try:
|
||||
metrics = kwargs["app"].config["INSTANCES"].get_metrics("antibot")
|
||||
metrics = kwargs["app"].config["INSTANCES"].get_metrics("redis")
|
||||
|
||||
if metrics.get("redis_nb_keys") is None:
|
||||
metrics["redis_nb_keys"] = 0
|
||||
|
|
|
|||
|
|
@ -1277,9 +1277,6 @@ def custom_plugin(plugin: str):
|
|||
if key.upper().startswith("USE_"):
|
||||
use_key = key
|
||||
|
||||
print("use key :", flush=True)
|
||||
print(use_key, flush=True)
|
||||
|
||||
# Case no USE_<NAME>, it means always show
|
||||
if not use_key:
|
||||
is_used = True
|
||||
|
|
|
|||
|
|
@ -440,17 +440,13 @@ class Instances:
|
|||
for instance in self.get_instances():
|
||||
try:
|
||||
resp, ping_data = instance.ping(plugin_id)
|
||||
print("res", flush=True)
|
||||
print(resp, flush=True)
|
||||
except:
|
||||
print("exception", flush=True)
|
||||
print(format_exc(), flush=True)
|
||||
continue
|
||||
|
||||
if not resp:
|
||||
continue
|
||||
|
||||
if instance.name not in ping_data or ping_data[instance.name]["msg"] is None or ping_data[instance.name]["msg"] is not dict:
|
||||
if instance.name not in ping_data or ping_data[instance.name]["msg"] is None:
|
||||
continue
|
||||
|
||||
if ping_data[instance.name]["status"] == "success":
|
||||
|
|
|
|||
Loading…
Reference in a new issue