fix(remnawave): restore xtls-rprx-vision flow on CASCADE-DE during rollback
ansible-deploy / plan (push) Successful in 2s
ansible-lint / lint (push) Successful in 2s
ansible-deploy / deploy (core-net, ) (push) Successful in 21s

This commit is contained in:
karpenok committed 2026-11-18 14:52:18 +07:00
1 parent 6b302b9754
commit 571f5cb169
1 file changed
+8 -1
@@ -223,7 +223,13 @@ def ensure_cascade_credentials(
if ob.get("tag") == "CASCADE-DE": if ob.get("tag") == "CASCADE-DE":
vnext = (ob.get("settings") or {}).get("vnext") or [] vnext = (ob.get("settings") or {}).get("vnext") or []
rs = (ob.get("streamSettings") or {}).get("realitySettings") or {} rs = (ob.get("streamSettings") or {}).get("realitySettings") or {}
if vnext and vnext[0].get("port") == 443 and rs.get("serverName") == "yali.gunis.top": users = (vnext[0].get("users") or [{}]) if vnext else [{}]
if (
vnext
and vnext[0].get("port") == 443
and rs.get("serverName") == "yali.gunis.top"
and users[0].get("flow") == "xtls-rprx-vision"
):
ru_ok = True ru_ok = True
if has_cascade_inb and not has_steal_yali and ru_ok: if has_cascade_inb and not has_steal_yali and ru_ok:
@@ -285,6 +291,7 @@ def ensure_cascade_credentials(
if vnext: if vnext:
vnext[0]["port"] = 443 vnext[0]["port"] = 443
vnext[0]["users"][0]["id"] = creds["uuid"] vnext[0]["users"][0]["id"] = creds["uuid"]
vnext[0]["users"][0]["flow"] = "xtls-rprx-vision"
rs = (ob.get("streamSettings") or {}).get("realitySettings") or {} rs = (ob.get("streamSettings") or {}).get("realitySettings") or {}
rs["serverName"] = "yali.gunis.top" rs["serverName"] = "yali.gunis.top"
rs["publicKey"] = creds["pub"] rs["publicKey"] = creds["pub"]