changes
This commit is contained in:
6
app.py
6
app.py
@@ -291,10 +291,6 @@ def node_ha_services(node: str) -> Dict[str, str]:
|
||||
return {"crm_state": one("pve-ha-crm"), "lrm_state": one("pve-ha-lrm")}
|
||||
|
||||
def units_for_node(node: str) -> Dict[str, str]:
|
||||
"""
|
||||
Preferuj /nodes/<node>/services. Normalizuj nazwy (bez .service)
|
||||
i mapuj różne pola na 'active'/'inactive'.
|
||||
"""
|
||||
wanted = {"watchdog-mux", "pve-ha-crm", "pve-ha-lrm"}
|
||||
svc = get_json(["pvesh", "get", f"/nodes/{node}/services"]) or []
|
||||
states: Dict[str, str] = {}
|
||||
@@ -438,7 +434,7 @@ def api_disable():
|
||||
if __name__ == "__main__":
|
||||
import argparse
|
||||
p = argparse.ArgumentParser()
|
||||
p.add_argument("--bind", default="127.0.0.1:8088", help="addr:port")
|
||||
p.add_argument("--bind", default="127.0.0.1:8007", help="addr:port")
|
||||
p.add_argument("--node", default=DEFAULT_NODE, help="default node")
|
||||
args = p.parse_args()
|
||||
DEFAULT_NODE = args.node
|
||||
|
Reference in New Issue
Block a user