From dcfb7805cd1c6ae4eced526124267956f8cdd54a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Arag=C3=B3n?= Date: Fri, 10 Jul 2026 11:36:59 +0000 Subject: [PATCH] debug(ci): print job container network info before auto-discovery Adds Step 0a that prints hostname -I, ip route, and a direct curl to 192.168.1.30:9000. This is to verify whether the runner external (in network_mode: host) is actually propagating host networking to the job containers it spawns. Symptom: deploy step fails with 'Failed to connect to 192.168.1.30 port 9000' even from the external runner. To be removed once we know. --- .gitea/workflows/ci-cd.yaml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.gitea/workflows/ci-cd.yaml b/.gitea/workflows/ci-cd.yaml index df6bc1b..f28398d 100644 --- a/.gitea/workflows/ci-cd.yaml +++ b/.gitea/workflows/ci-cd.yaml @@ -71,6 +71,20 @@ jobs: run: | set -euo pipefail + echo "--- Step 0a: debug network from inside the job container ---" + echo "hostname: $(hostname)" + echo "hostname -I:" + hostname -I 2>/dev/null || echo "(none)" + echo "ip -4 addr show (eth* only):" + ip -4 addr show 2>/dev/null | grep -E "^[0-9]+:|inet " | head -20 + echo "ip route:" + ip route 2>/dev/null + echo "ip route show default:" + ip -4 route show default 2>/dev/null + echo "curl to 192.168.1.30:9000 (5s timeout):" + curl -sS -o /dev/null -w ' HTTP=%{http_code} time=%{time_total}s\n' --max-time 5 "http://192.168.1.30:9000/api/status" 2>&1 || echo " (curl failed)" + echo "---" + echo "--- Step 0: auto-discover a reachable Portainer URL ---" # The runner creates an ephemeral docker network per job, so the # canonical PORTAINER_URL (e.g. http://192.168.1.30:9000) often isn't