From 8d6db6edbbb1736c561cb82a1b6d254977e96e34 Mon Sep 17 00:00:00 2001 From: Rui Date: Sun, 17 May 2026 03:21:25 +0200 Subject: [PATCH] feat: select internal VPN IP for awareness to satisfy compliance filters --- templates/agent_executor.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/templates/agent_executor.py b/templates/agent_executor.py index bdfd689..1bc21c4 100644 --- a/templates/agent_executor.py +++ b/templates/agent_executor.py @@ -153,7 +153,8 @@ class SwarmAgent: self.setup_workspace() # Identificação de Localização Automática - vps_ip = subprocess.getoutput("hostname -I").split()[0] + ips = subprocess.getoutput("hostname -I").split() + vps_ip = next((ip for ip in ips if ip.startswith("10.99.")), ips[0] if ips else "127.0.0.1") vps_name = subprocess.getoutput("hostname") # Carrega a Doutrina de Agentes