Update socat to connect to VM SSH on port 2222
Some checks failed
Test / test (push) Has been cancelled

Windows SSH moved from port 22 to 2222, freeing port 22 for IBM i portproxy.

🤖 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 09:52:54 +00:00
parent e103847796
commit 6abe3aef77

View File

@@ -67,9 +67,9 @@ get_container_ip() {
iptables -C FORWARD -d "$WINDOWS_IP" -j ACCEPT 2>/dev/null || \ iptables -C FORWARD -d "$WINDOWS_IP" -j ACCEPT 2>/dev/null || \
iptables -A FORWARD -d "$WINDOWS_IP" -j ACCEPT iptables -A FORWARD -d "$WINDOWS_IP" -j ACCEPT
# Forward port 2222 to VM's SSH (22) for VM access # Forward port 2222 to VM's SSH (2222) for VM access
pkill -f "socat.*:2222" 2>/dev/null || true pkill -f "socat.*:2222" 2>/dev/null || true
socat TCP-LISTEN:2222,fork,reuseaddr TCP:"$WINDOWS_IP":22 & socat TCP-LISTEN:2222,fork,reuseaddr TCP:"$WINDOWS_IP":2222 &
echo "[rego-tunnel] SSH to VM available on port 2222" echo "[rego-tunnel] SSH to VM available on port 2222"
# Add DNAT rules for port forwarding # Add DNAT rules for port forwarding