rego-tunnel: detect container IP by subnet instead of interface name
Some checks failed
Test / test (push) Has been cancelled

Interface order is not consistent. Search for 172.31.x.x subnet instead.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2025-12-19 08:58:44 +00:00
parent 27b496893f
commit 0aadef4705

View File

@@ -28,8 +28,8 @@ get_windows_ip() {
} }
get_container_ip() { get_container_ip() {
# Get container's external IP (vpn_static-rego - eth0) # Get container's external IP on 172.31.x.x subnet (vpn_static-rego)
ip -4 addr show eth0 2>/dev/null | awk '/inet / {print $2}' | cut -d/ -f1 ip -4 addr 2>/dev/null | grep -oE '172\.31\.[0-9]+\.[0-9]+' | head -1
} }
( (