From 685af019f554d428ac62355606235f91ee90231b Mon Sep 17 00:00:00 2001 From: Vitaliy Filippov Date: Sat, 28 Dec 2024 20:52:27 +0300 Subject: [PATCH] Allow :: and 0.0.0.0 as local IPs in antietcd_adapter --- mon/antietcd_adapter.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mon/antietcd_adapter.js b/mon/antietcd_adapter.js index b7da3054..b18016a0 100644 --- a/mon/antietcd_adapter.js +++ b/mon/antietcd_adapter.js @@ -23,6 +23,9 @@ class AntiEtcdAdapter }, {})); const cfg_port = config.antietcd_port; const is_local = local_ips(true).reduce((a, c) => { a[c] = true; return a; }, {}); + is_local['0.0.0.0'] = true; + is_local['::'] = true; + is_local[''] = true; const selected = cluster.map(s => s.split(':', 2)).filter(ip => is_local[ip[0]] && (!cfg_port || ip[1] == cfg_port)); if (selected.length > 1) {