From ec257ef55f64478f670fb22581f7b4d9ed6d65e0 Mon Sep 17 00:00:00 2001 From: Shaun Arman Date: Sat, 6 Jun 2026 19:46:04 -0500 Subject: [PATCH] docs(kubernetes): add comment about dynamic port allocation limitation --- src-tauri/src/commands/kube.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src-tauri/src/commands/kube.rs b/src-tauri/src/commands/kube.rs index 0e7c14b3..fd6e3947 100644 --- a/src-tauri/src/commands/kube.rs +++ b/src-tauri/src/commands/kube.rs @@ -465,10 +465,14 @@ pub async fn start_port_forward( // Use kubectl's dynamic port binding by specifying 0 as local port // This avoids race condition with port allocation + // Note: Dynamic port allocation (when local_port=0) currently returns 0 + // The actual allocated port could be captured from kubectl's stderr/stdout + // but this requires parsing kubectl output which is complex and error-prone + // For now, users must specify a local port or use the default behavior let local_port = if request.local_port > 0 { request.local_port } else { - 0 // Let kubectl allocate dynamically + 0 // Let kubectl allocate dynamically (currently not captured) }; info!(